Skip to content

Commit

Permalink
Merge pull request wasmerio#385 from wasmerio/feature/better-tar-install
Browse files Browse the repository at this point in the history
Improved installer
  • Loading branch information
syrusakbary authored Apr 23, 2019
2 parents f104b2c + 15d7056 commit 486c43f
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 3 deletions.
16 changes: 16 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,10 @@ jobs:
- image: circleci/rust:latest
steps:
- checkout
- run:
name: "Pull dependencies"
command: |
git clone [email protected]:wasmerio/wapm-cli.git
- restore_cache:
keys:
- v8-cargo-cache-linux-nightly-{{ arch }}-{{ checksum "Cargo.lock" }}
Expand Down Expand Up @@ -178,6 +182,7 @@ jobs:
command: |
export LLVM_SYS_70_PREFIX="`pwd`/clang+llvm-7.0.0-x86_64-linux-gnu-ubuntu-16.04/"
make production-release
cargo build --release --manifest-path wapm-cli/Cargo.toml --features telemetry
mkdir -p artifacts
VERSION=$(cargo pkgid | cut -d# -f2 | cut -d: -f2)
# GIT_VERSION=$(git describe --exact-match --tags)
Expand All @@ -202,13 +207,20 @@ jobs:
- target/release/.fingerprint
- target/release/build
- target/release/deps
- wapm-cli/target/release/.fingerprint
- wapm-cli/target/release/build
- wapm-cli/target/release/deps
key: v8-cargo-cache-linux-nightly-{{ arch }}-{{ checksum "Cargo.lock" }}

test-and-build-macos:
macos:
xcode: "9.0"
steps:
- checkout
- run:
name: "Pull dependencies"
command: |
git clone [email protected]:wasmerio/wapm-cli.git
- restore_cache:
keys:
- v8-cargo-cache-darwin-nightly-{{ arch }}-{{ checksum "Cargo.lock" }}
Expand Down Expand Up @@ -263,6 +275,7 @@ jobs:
export PATH="$HOME/.cargo/bin:$PATH"
export LLVM_SYS_70_PREFIX="`pwd`/clang+llvm-7.0.0-x86_64-apple-darwin/"
make production-release
cargo build --release --manifest-path wapm-cli/Cargo.toml --features telemetry
mkdir -p artifacts
make build-install
cp ./wasmer.tar.gz ./artifacts/$(./binary-name.sh)
Expand All @@ -281,6 +294,9 @@ jobs:
- target/release/.fingerprint
- target/release/build
- target/release/deps
- wapm-cli/target/release/.fingerprint
- wapm-cli/target/release/build
- wapm-cli/target/release/deps
key: v8-cargo-cache-darwin-nightly-{ arch }}-{{ checksum "Cargo.lock" }}

test-rust-nightly:
Expand Down
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,9 @@ precommit: lint test

build-install:
mkdir -p ./install/bin
cp ./wapm-cli/target/release/wapm ./install/bin/
cp ./target/release/wasmer ./install/bin/
tar -C ./install -zcvf wasmer.tar.gz bin/wasmer
tar -C ./install -zcvf wasmer.tar.gz bin/wapm bin/wasmer

# For installing the contents locally
do-install:
Expand Down
5 changes: 3 additions & 2 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,9 @@ wasmer_link() {
)

printf "$green> Successfully installed $version!\n\n${reset}If you want to have the command available now please execute:\nsource $HOME/.wasmer/wasmer.sh$reset\n"
printf "\nOtherwise, wasmer will be available the next time you open the terminal.\n"
printf "\nOtherwise, wasmer and wapm will be available the next time you open the terminal.\n"
echo "Note: during the alpha release of wapm telemetry is enabled by default; if you would like to opt out, run \`wapm config set telemetry.enabled false\`."
echo "If you notice anything wrong or have any issues, please file a bug at https://github.com/wasmerio/wapm-cli :)"
fi
}

Expand Down Expand Up @@ -292,7 +294,6 @@ wasmer_install() {
# exit 0
# fi
# fi

wasmer_download # $1 $2
wasmer_link
wasmer_reset
Expand Down

0 comments on commit 486c43f

Please sign in to comment.