generated from version-fox/vfox-plugin-template
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Showing
2 changed files
with
43 additions
and
31 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 |
---|---|---|
|
@@ -11,9 +11,11 @@ jobs: | |
strategy: | ||
matrix: | ||
# ref: https://github.com/actions/runner-images | ||
os: [ ubuntu-latest, macos-latest, windows-latest] | ||
os: [ ubuntu-latest, macos-latest] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
- name: install vfox (Linux) | ||
if: runner.os == 'Linux' | ||
run: | | ||
|
@@ -30,26 +32,9 @@ jobs: | |
echo 'eval "$(vfox activate bash)"' >> ~/.bashrc | ||
echo 'eval "$(vfox activate zsh)"' >> ~/.zshrc | ||
- name: install vfox (Windows) | ||
if: runner.os == 'Windows' | ||
shell: pwsh | ||
run: | | ||
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser | ||
Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression | ||
scoop install vfox | ||
vfox -v | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Generate PHP plugin | ||
if: runner.os != 'Windows' | ||
run: | | ||
zip -r php.zip ./ | ||
- name: Generate PHP plugin | ||
if: runner.os == 'Windows' | ||
run: | | ||
Compress-Archive -Path .\* -DestinationPath .\php.zip | ||
- name: Install packages | ||
if: runner.os == 'Linux' | ||
|
@@ -63,25 +48,12 @@ jobs: | |
vfox add -s php.zip | ||
vfox install [email protected] | ||
# php -v | ||
# php -m | ||
# composer -V | ||
- name: Test | ||
if: runner.os != 'Windows' | ||
run: | | ||
vfox use [email protected] | ||
php -v | ||
php -m | ||
composer -V | ||
- name: Test | ||
if: runner.os == 'Windows' | ||
shell: pwsh | ||
run: | | ||
vfox use -p [email protected] | ||
Invoke-Expression "$(vfox activate pwsh)" | ||
php -v | ||
php -m | ||
composer -V | ||
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,40 @@ | ||
name: Test workflow | ||
|
||
on: | ||
pull_request: | ||
# push: | ||
schedule: | ||
- cron: 0 0 * * 5 | ||
|
||
jobs: | ||
plugin-test-linux: | ||
strategy: | ||
matrix: | ||
# ref: https://github.com/actions/runner-images | ||
os: [ windows-latest] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: install vfox and test(Windows) | ||
shell: pwsh | ||
run: | | ||
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser | ||
Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression | ||
scoop install vfox | ||
Compress-Archive -Path .\* -DestinationPath .\php.zip | ||
vfox -v | ||
vfox add -s php.zip | ||
vfox install [email protected] | ||
- name: Test | ||
shell: pwsh | ||
run: | | ||
vfox use -p [email protected] | ||
Invoke-Expression "$(vfox activate pwsh)" | ||
php -v | ||
php -m | ||
composer -V | ||