Debugging GNU make

make -d should give you more than enough information to debug your makefile. Be warned: it will take some time and effort to analyze the output but loading the output into your favorite editor and doing searches will assist a lot. You can greatly reduce the amount of debugging output if you specify the specific … Read more

Enumerate or list all variables in a program of [your favorite language here] [closed]

In python, using locals which returns a dictionary containing all the local bindings, thus, avoiding eval: >>> foo1 = “Hello world” >>> foo2 = “bar” >>> foo3 = {“1″:”a”, … “2”:”b”} >>> foo4 = “1+1” >>> import pprint >>> pprint.pprint(locals()) {‘__builtins__’: <module ‘__builtin__’ (built-in)>, ‘__doc__’: None, ‘__name__’: ‘__main__’, ‘foo1’: ‘Hello world’, ‘foo2’: ‘bar’, ‘foo3’: {‘1’: … Read more

How to debug a Gradle build.gradle file (in a debugger, with breakpoints)?

There is the easier way: just add in your command line -Dorg.gradle.debug=true –no-daemon For example: gradle nameOfTask -Dorg.gradle.debug=true –no-daemon Then you should start your IDE and run remote debugging with localhost port 5005, that all. Gradle is waiting to you, because standard option server=y org.gradle.debug When set to true, Gradle will run the build with … Read more

Debugging monit

I’ve had the same problem. Using monit’s verbose command-line option helps a bit, but I found the best way was to create an environment as similar as possible to the monit environment and run the start/stop program from there. # monit runs as superuser $ sudo su # the -i option ignores the inherited environment … Read more

How to debug web sites on mobile devices?

This is the correct answer, not sure why Blaine only left it as a comment! As of iOS 6 Remote Debugging is available: https://stackoverflow.com/a/12762449/72428 On OS X you can use the Safari web inspector on the iOS Simulator AND iOS 6 devices. First enable the Developer menu in Safari on your Desktop. Next, enable remote … Read more