-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tools: improve
v symlink -githubci
diagnostic message, when used ou…
…tside CIs or with sudo (#21340)
- Loading branch information
Showing
2 changed files
with
94 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,88 @@ | ||
name: V Symlink Works | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
paths: | ||
- 'cmd/tools/vsymlink.v' | ||
- '.github/workflows/check_symlink_works.yml' | ||
pull_request: | ||
paths: | ||
- 'cmd/tools/vsymlink.v' | ||
- '.github/workflows/check_symlink_works.yml' | ||
|
||
jobs: | ||
check-ubuntu-with-sudo: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Checkout V | ||
uses: actions/checkout@v4 | ||
- name: Build V | ||
run: make && sudo ./v symlink | ||
- name: Check if V is usable | ||
run: | | ||
pwd | ||
v version | ||
cd ~ | ||
pwd | ||
v version | ||
echo 'println(123)' > hi.v | ||
v run hi.v | ||
echo 'Using `sudo ./v symlink` :rocket: !!!' >> $GITHUB_STEP_SUMMARY | ||
check-ubuntu: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Checkout V | ||
uses: actions/checkout@v4 | ||
- name: Build V | ||
run: make && ./v symlink -githubci | ||
- name: Check if V is usable | ||
run: | | ||
pwd | ||
v version | ||
cd ~ | ||
pwd | ||
v version | ||
echo 'println(123)' > hi.v | ||
v run hi.v | ||
echo "Everything was fine :rocket:" >> $GITHUB_STEP_SUMMARY | ||
check-macos: | ||
runs-on: macos-13 | ||
steps: | ||
- name: Checkout V | ||
uses: actions/checkout@v4 | ||
- name: Build V | ||
run: make && ./v symlink -githubci | ||
- name: Check if V is usable | ||
run: | | ||
pwd | ||
v version | ||
cd ~ | ||
pwd | ||
v version | ||
echo 'println(123)' > hi.v | ||
v run hi.v | ||
echo "Everything fine on macos too :rocket:" >> $GITHUB_STEP_SUMMARY | ||
check-windows: | ||
runs-on: windows-2019 | ||
steps: | ||
- name: Checkout V | ||
uses: actions/checkout@v4 | ||
- name: Build V | ||
run: | | ||
.\make.bat | ||
.\v.exe symlink -githubci | ||
- name: Check if V is usable | ||
shell: bash | ||
run: | | ||
pwd | ||
v version | ||
cd ~ | ||
pwd | ||
v version | ||
echo 'println(123)' > hi.v | ||
v run hi.v | ||
echo "All fine on Windows as well :rocket:" >> $GITHUB_STEP_SUMMARY |
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