Skip to content

Commit 35da516

Browse files
rashil2000niheaven
andauthored
(chore): Migrate CI to GitHub Actions (#8124)
* Delete appveyor.yml * Create ci.yml * Update test.ps1 * Update README.md * Update test.ps1 * Apply suggestions from code review Co-authored-by: Hsiao-nan Cheung <[email protected]> Co-authored-by: Hsiao-nan Cheung <[email protected]>
1 parent 95612a1 commit 35da516

File tree

4 files changed

+54
-42
lines changed

4 files changed

+54
-42
lines changed

Diff for: .github/workflows/ci.yml

+48
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Tests
2+
3+
on:
4+
pull_request:
5+
push:
6+
workflow_dispatch:
7+
8+
jobs:
9+
test_powershell:
10+
name: WindowsPowerShell
11+
runs-on: windows-latest
12+
steps:
13+
- name: Checkout Bucket
14+
uses: actions/checkout@v2
15+
with:
16+
fetch-depth: 2
17+
path: 'my_bucket'
18+
- name: Checkout Scoop
19+
uses: actions/checkout@v2
20+
with:
21+
repository: ScoopInstaller/Scoop
22+
path: 'scoop_core'
23+
- name: Init and Test
24+
shell: powershell
25+
run: |
26+
$env:SCOOP_HOME="$(Convert-Path '.\scoop_core')"
27+
.\scoop_core\test\bin\init.ps1
28+
.\my_bucket\bin\test.ps1
29+
test_pwsh:
30+
name: PowerShell
31+
runs-on: windows-latest
32+
steps:
33+
- name: Checkout Bucket
34+
uses: actions/checkout@v2
35+
with:
36+
fetch-depth: 2
37+
path: 'my_bucket'
38+
- name: Checkout Scoop
39+
uses: actions/checkout@v2
40+
with:
41+
repository: ScoopInstaller/Scoop
42+
path: 'scoop_core'
43+
- name: Init and Test
44+
shell: pwsh
45+
run: |
46+
$env:SCOOP_HOME="$(Convert-Path '.\scoop_core')"
47+
.\scoop_core\test\bin\init.ps1
48+
.\my_bucket\bin\test.ps1

Diff for: README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Scoop Extras [![Build Status](https://ci.appveyor.com/api/projects/status/ve0l0lw60hijwbs8?svg=true)](https://ci.appveyor.com/project/r15ch13/scoopinstaller-extras "Build Status") [![Excavator](https://github.com/ScoopInstaller/Extras/actions/workflows/excavator.yml/badge.svg)](https://github.com/ScoopInstaller/Extras/actions/workflows/excavator.yml)
1+
# Scoop Extras [![Tests](https://github.com/ScoopInstaller/Extras/actions/workflows/ci.yml/badge.svg)](https://github.com/ScoopInstaller/Extras/actions/workflows/ci.yml) [![Excavator](https://github.com/ScoopInstaller/Extras/actions/workflows/excavator.yml/badge.svg)](https://github.com/ScoopInstaller/Extras/actions/workflows/excavator.yml)
22

33
Extra manifests for [Scoop](https://scoop.sh), the Windows command-line installer. For manifests that don't fit the [Main criteria](https://github.com/ScoopInstaller/Scoop/wiki/Criteria-for-including-apps-in-the-main-bucket).
44

Diff for: appveyor.yml

-39
This file was deleted.

Diff for: bin/test.ps1

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
1-
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Resolve-Path (scoop prefix scoop) }
2-
Invoke-Pester "$psscriptroot/.."
1+
#Requires -Modules @{ ModuleName = 'Pester'; MaximumVersion = '4.99' }
2+
3+
if(!$env:SCOOP_HOME) { $env:SCOOP_HOME = Convert-Path (scoop prefix scoop) }
4+
$result = Invoke-Pester "$PSScriptRoot\.." -PassThru
5+
exit $result.FailedCount

0 commit comments

Comments
 (0)