The little things give you away... A collection of various small helper stuff
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 
 

11 líneas
573 B

  1. #!/bin/bash
  2. # Usage: create a file foo.c, make foo a symlink to this script
  3. # When foo is executed, this script silently compiles foo.c into .make-and-exec-binaries/foo and execs that with the arguments provided.
  4. # The compilation goes through make, so later invocations directly exec the binary with little delay.
  5. # To customise the compilation, you can set a CFLAGS env var before running foo.
  6. set -e
  7. name="$(basename "$0")"
  8. cd "$(dirname "$0")"
  9. make --file .make-and-exec-Makefile --silent ".make-and-exec-binaries/${name}"
  10. exec "./.make-and-exec-binaries/${name}" "$@"