Assuming you llvm installed (comes as standard on Mac OS Mavrick xtools)
Create a helloworld.c file:
#include<stdio.h>
int main()
{
int x=3;
ECHO OFF | |
REM This is to tell IronRuby where to find gems. | |
SET GEM_PATH=c:\ruby\lib\ruby\gems\1.8 | |
@" C:\Program Files\IronRuby 0.9.2\bin\ir.exe" "c:\ruby\bin\cucumber" %* --no-color |
Presentation slides and list of commds are available at: | |
https://github.com/gregmalcolm/unix_for_programmers_demo | |
NOTE: I used a Mac with OSX for this demo. Other unixes will differ slightly in behavior! | |
=========== | |
Preparation | |
=========== | |
If you're running the scripts in my demo, make sure they're set to executable |
Presentation slides and list of commds are available at: | |
https://github.com/gregmalcolm/unix_for_programmers_demo | |
NOTE: I used a Mac with OSX for this demo. Other unixes will differ slightly in behavior! | |
Examples are all written in Python 2.7 | |
=========== | |
Preparation | |
=========== |
Ruby: | |
https://gist.github.com/1156222 | |
Python: | |
https://gist.github.com/1241642 |
Rule 1: Get as far away from the door as possible | |
Rule 2: Never stand next to another dude | |
Rule 2, Exception 1: There is a line at the door | |
Rule 2, Exception 2: Someone else has already broken Rule 2 | |
Rule 3: Never stand next to two other dudes |
#!/bin/bash | |
args="$*" | |
first="$1" | |
if [[ "$first" == "" ]]; then | |
# Open mvim at the current directory | |
args="." | |
else | |
if [[ ! -a "$first" ]]; then | |
# If the file doesn't exist yet, create it |
#!/bin/bash | |
# 'Save' the folder name | |
alias hhh='echo $PWD > ~/.projectdir' | |
# Return to the project folder | |
alias hh='projectdir=$(cat ~/.projectdir) && cd $projectdir' | |
Assuming you llvm installed (comes as standard on Mac OS Mavrick xtools)
Create a helloworld.c file:
#include<stdio.h>
int main()
{
int x=3;