-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
.github/workflows: Use ssh-runner.yml from weshnet (not berty)
Signed-off-by: Jeff Thompson <[email protected]>
- Loading branch information
Showing
2 changed files
with
14 additions
and
51 deletions.
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 |
---|---|---|
|
@@ -3,16 +3,16 @@ on: | |
workflow_dispatch: | ||
inputs: | ||
os: | ||
description: "Operating System" | ||
description: 'Operating System' | ||
required: true | ||
default: ubuntu-latest | ||
type: choice | ||
options: | ||
- ubuntu-latest | ||
- macos-latest | ||
- windows-latest | ||
- ubuntu-latest | ||
- macos-latest | ||
- windows-latest | ||
mod: | ||
description: "Install Go/Node modules" | ||
description: 'Install Go/Node modules' | ||
required: true | ||
default: true | ||
type: boolean | ||
|
@@ -43,64 +43,29 @@ jobs: | |
asdf install golang | ||
echo "go_version=$(asdf current golang | xargs | cut -d ' ' -f 2)" >> $GITHUB_ENV | ||
- name: Setup node | ||
if: runner.os != 'Windows' | ||
run: | | ||
asdf plugin add nodejs | ||
asdf install nodejs | ||
echo "node_version=$(asdf current nodejs | xargs | cut -d ' ' -f 2)" >> $GITHUB_ENV | ||
- name: Setup yarn | ||
if: runner.os != 'Windows' | ||
run: | | ||
asdf plugin add yarn | ||
asdf install yarn | ||
- name: Cache go modules | ||
if: github.event.inputs.mod == 'true' && runner.os != 'Windows' | ||
uses: actions/[email protected] | ||
with: | ||
path: ~/go/pkg/mod | ||
key: ${{ runner.os }}-go-${{ env.go_version }}-${{ env.json_cache-versions_go }}-${{ hashFiles('go/**/go.sum') }} | ||
key: ${{ runner.os }}-go-${{ env.go_version }}-${{ env.json_cache-versions_go }}-${{ hashFiles('**/go.sum') }} | ||
restore-keys: ${{ runner.os }}-go-${{ env.go_version }}-${{ env.json_cache-versions_go }}- | ||
|
||
- name: Cache node modules | ||
if: github.event.inputs.mod == 'true' && runner.os != 'Windows' | ||
uses: actions/[email protected] | ||
with: | ||
path: js/node_modules | ||
key: ${{ runner.OS }}-node-${{ env.node_version }}-${{ env.json_cache-versions_node }}-${{ hashFiles('js/yarn.lock') }} | ||
restore-keys: ${{ runner.OS }}-node-${{ env.node_version }}-${{ env.json_cache-versions_node }}- | ||
|
||
- name: Fetch go modules | ||
if: github.event.inputs.mod == 'true' && runner.os != 'Windows' | ||
working-directory: go | ||
working-directory: . | ||
run: go mod tidy | ||
|
||
- name: Fetch node modules | ||
if: github.event.inputs.mod == 'true' && runner.os != 'Windows' | ||
working-directory: js | ||
run: make node_modules | ||
|
||
- name: Install emacs | ||
shell: bash | ||
run: | | ||
if [ "$RUNNER_OS" == "Linux" ]; then | ||
sudo apt-get install -y emacs | ||
elif [ "$RUNNER_OS" == "Windows" ]; then | ||
choco install emacs | ||
else | ||
echo "Already installed!" | ||
fi | ||
- name: Install LazyVim | ||
shell: bash | ||
run: | | ||
if [ "$RUNNER_OS" == "Windows" ]; then | ||
git clone https://github.com/LazyVim/starter $env:LOCALAPPDATA\nvim | ||
else | ||
git clone https://github.com/LazyVim/starter ~/.config/nvim | ||
fi | ||
if [ "$RUNNER_OS" == "Linux" ]; then | ||
sudo apt-get install -y emacs | ||
elif [ "$RUNNER_OS" == "Windows" ]; then | ||
choco install emacs | ||
else | ||
echo "Already installed!" | ||
fi | ||
- name: Setup tmate session | ||
uses: mxschmitt/action-tmate@v3 | ||
|
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 |
---|---|---|
@@ -1,4 +1,2 @@ | ||
golang 1.22.5 | ||
golangci-lint 1.57.2 | ||
# Add nodejs for the CI workflows | ||
nodejs 16.16.0 |