command-line-tool

How to debug python CLI that takes stdin?

非 Y 不嫁゛ 提交于 2019-11-29 06:49:34
问题 I'm trying to debug a Python CLI I wrote that can take its arguments from stdin. A simple test case would have the output of echo "test" | python mytool.py be equivalent to the output of python mytool.py test I'd like to debug some issues with this tool, so I tried to run this: echo "test" | pdb mytool.py But I get this output, then pdb exits: > /path/to/mytool.py(5)<module>() -> ''' (Pdb) *** NameError: name 'test' is not defined (Pdb) The same thing occurs when I add -m python to the

Cocoa wrapper for an interactive Unix command

為{幸葍}努か 提交于 2019-11-29 06:45:02
Ok, so I know you can make an NSTask to run command line tools with Objective-C: NSTask *task; task = [[NSTask alloc] init]; [task setLaunchPath: @"/usr/bin/gdb"]; [task launch]; I'm just wondering if there's a way to communicate with interactive command line tools such a as gdb . This would involve giving the command inputs based on user interaction (like run , kill or quit with gdb ) and then reacting based on the information it outputs. You can use NSTask's setStandardInput: , setStandardOutput: and setStandardError: selectors in conjunction with NSPipe instances to communicate with the

Install gnuplot 5.0.1 on OSX

江枫思渺然 提交于 2019-11-29 01:03:18
I downloaded the source files for gnuplot 5.0.1 (gnuplot-5.0.1.tar.gz) from the source forge page . I also installed the Command Line Tools on my OS X 10.7.5 so that I have gcc and make in the /usr/bin folder. I followed the installation instructions found in INSTALL.gnu file of the tarball: I ran the configure file and typed make , make check , make install , and make clean . With these commands, gnuplot is located in /usr/local/bin/ . The make check command outputs a lot of lines in the shell before testing many gnuplot scripts. I could actually visualize the plots and I thought "great, it

Mac OS app, sandbox with command line tool?

我与影子孤独终老i 提交于 2019-11-28 21:16:48
I've made an app which includes a command-line tool. I have enabled the app's sandbox, and tested that it works. I've also code-signed both the app and the command line tool. But when I upload the app to iTunes, I received a email telling me "App sandbox not enabled". Apparently I need to set entitlement file of key com.apple.security.app-sandbox with true value, and list the executables: /Contents/MacOS/myApp and /contents/Frameworks/x86/myCommandLineTool . I'm sure I've enabled sandbox in Xcode, so I thought the problem was with the command line tool. How can I enable sandbox for command

Mac OS app, sandbox with command line tool?

╄→гoц情女王★ 提交于 2019-11-27 20:58:01
问题 I've made an app which includes a command-line tool. I have enabled the app's sandbox, and tested that it works. I've also code-signed both the app and the command line tool. But when I upload the app to iTunes, I received a email telling me "App sandbox not enabled". Apparently I need to set entitlement file of key com.apple.security.app-sandbox with true value, and list the executables: /Contents/MacOS/myApp and /contents/Frameworks/x86/myCommandLineTool . I'm sure I've enabled sandbox in

Xcode 6.1 - How to uninstall command line tools?

主宰稳场 提交于 2019-11-27 20:21:58
I installed Xcode command line tool by issuing xcode-select --install ; now I want to uninstall it (without uninstalling Xcode). I've tried sudo /Developer/Library/uninstall-devtools --mode=all but then I get the error sudo: /Developer/Library/uninstall-devtools: command not found Aaron Brager If you installed the command line tools separately, delete them using: rm -rf /Library/Developer/CommandLineTools Durai Amuthan.H An excerpt from an apple technical note (Thanks to matthias-bauch ) Xcode includes all your command-line tools. If it is installed on your system, remove it to uninstall your

svn client binaries for windows

こ雲淡風輕ζ 提交于 2019-11-27 18:57:01
Where are the Windows binaries for the command-line version of SVN? Everywhere I search, it has to be some company's fancy client software with an installer. I'm working on a machine where I don't have administrator account. Just give me the plain command-line binaries, where the hell are they? gix The former direct links don't work, but the subversion project now provides several offsite links to Windows binaries: http://subversion.apache.org/packages.html#windows I use Slik SVN . It doesn't require a bunch of registration information like the CollabNet one does. Evan Get the version from

Install gnuplot 5.0.1 on OSX

老子叫甜甜 提交于 2019-11-27 15:34:35
问题 I downloaded the source files for gnuplot 5.0.1 (gnuplot-5.0.1.tar.gz) from the source forge page. I also installed the Command Line Tools on my OS X 10.7.5 so that I have gcc and make in the /usr/bin folder. I followed the installation instructions found in INSTALL.gnu file of the tarball: I ran the configure file and typed make , make check , make install , and make clean . With these commands, gnuplot is located in /usr/local/bin/ . The make check command outputs a lot of lines in the

command line tools for new 10.9 OSX for ruby gems?

大兔子大兔子 提交于 2019-11-27 11:13:13
After installing OSX Mavericks 10.9 demo, Im getting this after running bundle Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. /Users/sandric/.rvm/rubies/ruby-1.9.3-p194/bin/ruby extconf.rb extconf.rb:17: Use RbConfig instead of obsolete and deprecated Config. checking for socket() in -lsocket... *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options. Provided configuration options: --with-opt-dir --without-opt-dir

Superimposing two videos onto a static image?

一世执手 提交于 2019-11-27 10:53:39
I have two videos that I'd like to combine into a single video, in which both videos would sit on top of a static background image. (Think something like this .) My requirements are that the software I use is free, that it runs on OSX, and that I don't have to re-encode my videos an excessive number of times. I'd also like to be able to perform this operation from the command line or via script, since I'll be doing it a lot. (But this isn't strictly necessary.) I tried fiddling with ffmpeg for a couple of hours, but it just doesn't seem very well suited for post-processing. I could potentially