-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
524f2af
commit 3f15345
Showing
7 changed files
with
93 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/usr/bin/env bash | ||
|
||
PROJECT_DIR="$(pwd)" | ||
|
||
PATH_add ${PROJECT_DIR} | ||
PATH_add ${PROJECT_DIR}/node_modules/.bin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2.7.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
source 'https://rubygems.org' | ||
|
||
gem 'rake', '~> 13.0' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
GEM | ||
remote: https://rubygems.org/ | ||
specs: | ||
rake (13.0.3) | ||
|
||
PLATFORMS | ||
x86_64-darwin-19 | ||
|
||
DEPENDENCIES | ||
rake (~> 13.0) | ||
|
||
BUNDLED WITH | ||
2.2.6 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
task :default => :"contracts:compile" | ||
|
||
namespace :contracts do | ||
desc "Compile all contracts" | ||
task :compile do | ||
sh('npm run compile') | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
#!/usr/bin/env bash | ||
|
||
[ -n "$GO_DEBUG" ] && set -x | ||
set -e | ||
|
||
project_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
|
||
verbose="no" | ||
offline="no" | ||
skip_checks="no" | ||
|
||
missing_dependency="no" | ||
|
||
[ -n "$GO_DEBUG" ] && verbose="yes" | ||
[ -n "$GO_SKIP_CHECKS" ] && skip_checks="yes" | ||
[ -n "$GO_OFFLINE" ] && offline="yes" | ||
|
||
|
||
if [[ "$skip_checks" = "no" ]]; then | ||
echo "Checking for system dependencies." | ||
ruby_version="$(cat "$project_dir"/.ruby-version)" | ||
if ! type ruby >/dev/null 2>&1 || ! ruby -v | grep -q "$ruby_version"; then | ||
echo "This codebase requires Ruby $ruby_version." | ||
missing_dependency="yes" | ||
fi | ||
|
||
if ! type bundler >/dev/null 2>&1; then | ||
echo "This codebase requires Bundler." | ||
missing_dependency="yes" | ||
fi | ||
|
||
if [[ "$missing_dependency" = "yes" ]]; then | ||
echo "Please install missing dependencies to continue." | ||
exit 1 | ||
fi | ||
|
||
echo "All system dependencies present. Continuing." | ||
fi | ||
|
||
if [[ "$offline" = "no" ]]; then | ||
echo "Installing bundler." | ||
if [[ "$verbose" = "yes" ]]; then | ||
gem install --no-document bundler | ||
else | ||
gem install --no-document bundler > /dev/null | ||
fi | ||
|
||
echo "Installing ruby dependencies." | ||
if [[ "$verbose" = "yes" ]]; then | ||
bundle install | ||
else | ||
bundle install > /dev/null | ||
fi | ||
fi | ||
|
||
echo "Starting rake." | ||
if [[ "$verbose" = "yes" ]]; then | ||
time bundle exec rake --verbose "$@" | ||
else | ||
time bundle exec rake "$@" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters