Skip to content

Commit 7a27485

Browse files
andrewbirdPerditionC
authored andcommitted
CI: Add Github Action
1 parent 4e21e94 commit 7a27485

File tree

5 files changed

+47
-4
lines changed

5 files changed

+47
-4
lines changed

.gitattributes

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
* text eol=crlf
22
*.up -text
33
*.UP -text
4-
travis_*.sh text eol=lf
4+
ci_*.sh text eol=lf
55
.travis.yml text eol=lf
6+
.github/workflows/*.yml text eol=lf

.github/workflows/ci-build.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Build / Test / Upload snapshot
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
7+
jobs:
8+
build:
9+
10+
runs-on: ubuntu-20.04
11+
12+
steps:
13+
- uses: actions/checkout@v2
14+
15+
- name: Package install
16+
run: |
17+
sudo add-apt-repository ppa:tkchia/build-ia16
18+
sudo apt update
19+
sudo apt install gcc-ia16-elf nasm upx
20+
21+
- name: build
22+
run: ./ci_build.sh
23+
24+
- name: test
25+
run: ./ci_test.sh
26+
27+
- name: make snapshot name
28+
id: snapshotname
29+
run: |
30+
(
31+
today=`date -u +%F | tr '\n' '-'`
32+
s_sha=`echo -n ${GITHUB_SHA} | cut -c1-8`
33+
printf '::set-output name=fname::snapshot-%s%s\n' $today $s_sha
34+
)
35+
36+
- name: upload
37+
uses: actions/upload-artifact@v2
38+
with:
39+
name: ${{ steps.snapshotname.outputs.fname }}
40+
path: _output/K*.???

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ before_install:
1616
- echo "before_install"
1717

1818
install:
19-
- ./travis_build.sh
19+
- ./ci_build.sh
2020

2121
before_script:
2222
- echo "before_script"
2323

2424
script:
25-
- ./travis_test.sh
25+
- ./ci_test.sh

travis_build.sh renamed to ci_build.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ mv -i bin/KGC*.map bin/KGC*.sys _output/.
1818

1919
# Watcom
2020
if [ ! -d _watcom ] ; then
21-
[ -f ow-snapshot.tar.gz ] || wget https://github.com/open-watcom/open-watcom-v2/releases/download/Current-build/ow-snapshot.tar.gz
21+
[ -f ow-snapshot.tar.gz ] || wget --quiet https://github.com/open-watcom/open-watcom-v2/releases/download/Current-build/ow-snapshot.tar.gz
2222

2323
mkdir _watcom
2424
(cd _watcom && tar -xf ../ow-snapshot.tar.gz)
@@ -30,3 +30,5 @@ export WATCOM=$TRAVIS_BUILD_DIR/_watcom
3030
git clean -x -d -f -e _output -e _watcom -e ow-snapshot.tar.gz
3131
make all COMPILER=owlinux
3232
mv -i bin/KWC*.map bin/KWC*.sys _output/.
33+
34+
echo done
File renamed without changes.

0 commit comments

Comments
 (0)