mirror of
https://github.com/correl/rebar.git
synced 2024-11-27 11:09:55 +00:00
19 lines
418 B
Bash
Executable file
19 lines
418 B
Bash
Executable file
#!/bin/bash
|
|
|
|
# Fail on first error
|
|
set -e
|
|
|
|
## Check path for exiting rebar instance -- if it's around, use it
|
|
## for compilation (NOT installation!)
|
|
`which -s rebar`
|
|
if [ $? == 0 ]; then
|
|
rebar compile ${@}
|
|
else
|
|
## Use raw erlc..
|
|
erlc -I include -o ebin src/*.erl
|
|
fi
|
|
|
|
## Use application installer to perform actual installation
|
|
## into erlang distro
|
|
export ERL_LIBS=`(cd .. && pwd)`
|
|
priv/rebar install ${@}
|