Skip to content

chore: use NPM_TOKEN #34

chore: use NPM_TOKEN

chore: use NPM_TOKEN #34

Workflow file for this run

# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
name: build
on:
push:
# branches:
# - main
jobs:
cpp:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: boost
run: sudo apt-get update && sudo apt-get install -yq libboost-all-dev
- name: "build cpp"
run: |
cd cpp && echo "build cpp"
cmake -DCMAKE_BUILD_TYPE=Release .
make
for i in ./test/Release/*/test_*
do
$i
done
cs:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: "build cs"
run: |
cd cs/ipaddress && echo "build cs"
dotnet restore
dotnet build
dotnet test
dotnet build -c Release
dart:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- uses: dart-lang/setup-dart@v1
- name: "build dart"
run: |
cd dart/ipaddress && echo "build dart"
dart pub get
dart test
go:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: "build go"
run: |
cd go/ipaddress && echo "build go"
go version
go test -v
java:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: "build java"
run: |
cd java && echo "build java"
mvn test -B -Dmaven.javadoc.skip=true
js:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: "build js"
run: |
cd js && echo "build js"
npm install
npx prettier . --check
npm run build
npm run test
- name: publish
if: startsWith(github.ref, 'refs/tags/js@v')
working-directory: js
env:
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
run: |
npm version $(echo $GITHUB_REF | sed -e 's/^refs/tags/js@v//')
grep version package.json
npm publish --no-git-checks --access public
kotlin:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- uses: fwilhe2/setup-kotlin@main
- name: "build kotlin"
run: |
cd kotlin && echo "build kotlin"
./gradlew build
./gradlew test
ruby:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2"
- name: "build ruby"
run: |
cd ruby && echo "build ruby"
gem install jeweler
gem install test-unit
rake test
rust:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: "build rust"
run: |
cd rust && echo "build rust"
cargo test --release
swift:
runs-on: ['ubuntu-latest']
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: "build swift"
run: |
cd swift && echo "build swift"
swift build
swift test