Skip to content

Commit 7ce50dd

Browse files
authored
Merge pull request #31 from juliamatlab/CI
2 parents 8d222a2 + 27ee211 commit 7ce50dd

28 files changed

+2509
-369
lines changed

.appveyor.yml

-31
This file was deleted.

.github/workflows/CompatHelper.yml

+6-17
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,15 @@ name: CompatHelper
22

33
on:
44
schedule:
5-
- cron: '0 1 * * *'
6-
issues:
7-
types: [opened, reopened]
5+
- cron: '00 00 * * *'
86

97
jobs:
10-
build:
11-
runs-on: ${{ matrix.os }}
12-
strategy:
13-
matrix:
14-
julia-version: [1.2.0]
15-
julia-arch: [x86]
16-
os: [ubuntu-latest]
8+
CompatHelper:
9+
runs-on: ubuntu-latest
1710
steps:
18-
- uses: julia-actions/setup-julia@latest
19-
with:
20-
version: ${{ matrix.julia-version }}
21-
- name: Install dependencies
22-
run: julia -e 'using Pkg; Pkg.add(Pkg.PackageSpec(name = "CompatHelper", url = "https://github.com/bcbi/CompatHelper.jl.git"))'
23-
- name: CompatHelper.main
11+
- name: Pkg.add("CompatHelper")
12+
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
13+
- name: CompatHelper.main()
2414
env:
2515
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26-
JULIA_DEBUG: CompatHelper
2716
run: julia -e 'using CompatHelper; CompatHelper.main()'

.github/workflows/SnoopCompile.yml

+62-18
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,86 @@
11
name: SnoopCompile
22

3+
4+
# Edit based on your repository.
35
on:
4-
- push
6+
push:
7+
branches:
8+
# - 'master'
59

10+
defaults:
11+
run:
12+
shell: bash
613

714
jobs:
8-
build:
15+
SnoopCompile:
16+
if: "!contains(github.event.head_commit.message, '[skip ci]')"
917
runs-on: ${{ matrix.os }}
1018
strategy:
19+
fail-fast: false
1120
matrix:
12-
julia-version: ['nightly']
13-
julia-arch: [x64]
14-
os: [ubuntu-latest]
21+
# Uncomment other versions if you want multi-version signatures (should exactly match BotConfig.version):
22+
version:
23+
- '1.4.2'
24+
- '1.3.1'
25+
- '1.2.0'
26+
- '1.0.5'
27+
os:
28+
- ubuntu-latest
29+
- windows-latest
30+
- macos-latest
31+
arch:
32+
- x64
1533
steps:
1634
- uses: actions/checkout@v2
1735
- uses: julia-actions/setup-julia@latest
1836
with:
19-
version: ${{ matrix.julia-version }}
37+
version: ${{ matrix.version }}
2038
- name: Install dependencies
21-
run: julia --project -e 'using Pkg; Pkg.instantiate();'
22-
- name : Add SnoopCompile and current package
23-
run: julia -e 'using Pkg; Pkg.add("SnoopCompile"); Pkg.develop(PackageSpec(; path=pwd()));'
24-
- name: Install Test dependencies
25-
run: julia -e 'using SnoopCompile; SnoopCompile.addtestdep()'
39+
run: |
40+
julia --project -e 'using Pkg; Pkg.instantiate();'
41+
julia -e 'using Pkg; Pkg.add(PackageSpec(url = "https://github.com/aminya/SnoopCompile.jl", rev = "os_version_yml")); Pkg.develop(PackageSpec(; path=pwd())); using SnoopCompile; SnoopCompile.addtestdep();'
2642
- name: Generating precompile files
27-
run: julia --project=@. -e 'include("deps/SnoopCompile/snoopCompile.jl")'
43+
run: julia --project -e 'include("deps/SnoopCompile/snoop_bot.jl")'
2844
- name: Running Benchmark
29-
run: julia --project=@. -e 'include("deps/SnoopCompile/snoopBenchmark.jl")'
45+
run: julia --project -e 'include("deps/SnoopCompile/snoop_bench.jl")'
46+
- name: Upload all
47+
uses: actions/upload-artifact@v2
48+
with:
49+
path: ./
3050

31-
# https://github.com/marketplace/actions/create-pull-request
51+
Create_PR:
52+
if: "!contains(github.event.head_commit.message, '[skip ci]')"
53+
needs: SnoopCompile
54+
runs-on: ubuntu-latest
55+
steps:
56+
- uses: actions/checkout@v2
57+
- name: Download all
58+
uses: actions/download-artifact@v2
59+
- name: Move the content of the directory to the root
60+
run: |
61+
rsync -a artifact/* ./
62+
rm -d -r artifact
63+
- name: Discard unrelated changes
64+
run: |
65+
test -f 'Project.toml' && git checkout -- 'Project.toml'
66+
git ls-files 'Manifest.toml' | grep . && git checkout -- 'Manifest.toml'
67+
(git diff -w --no-color || git apply --cached --ignore-whitespace && git checkout -- . && git reset && git add -p) || echo done
68+
- name: Format precompile_includer.jl
69+
run: julia -e 'using Pkg; Pkg.add("JuliaFormatter"); using JuliaFormatter; format_file("src/precompile_includer.jl")'
3270
- name: Create Pull Request
3371
uses: peter-evans/create-pull-request@v2
3472
with:
3573
token: ${{ secrets.GITHUB_TOKEN }}
3674
commit-message: Update precompile_*.jl file
3775
committer: Amin Yahyaabadi <[email protected]>
38-
title: '[AUTO] Update precompile_*.jl file'
76+
title: "[AUTO] Update precompiles"
3977
labels: SnoopCompile
40-
branch: create-pull-request/SnoopCompile
41-
- name: Check output environment variable
42-
run: echo "Pull Request Number - ${{ env.PULL_REQUEST_NUMBER }}"
78+
branch: "SnoopCompile_AutoPR"
79+
80+
81+
Skip:
82+
if: "contains(github.event.head_commit.message, '[skip ci]')"
83+
runs-on: ubuntu-latest
84+
steps:
85+
- name: Skip CI 🚫
86+
run: echo skip ci

.github/workflows/TagBot.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
name: TagBot
22
on:
3-
schedule:
4-
- cron: 0 * * * *
3+
create
54
jobs:
65
TagBot:
76
runs-on: ubuntu-latest

.github/workflows/ci.yml

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: CI
2+
on:
3+
- push
4+
- pull_request
5+
jobs:
6+
test:
7+
if: "!contains(github.event.head_commit.message, '[skip ci]')"
8+
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
9+
runs-on: ${{ matrix.os }}
10+
strategy:
11+
fail-fast: false
12+
matrix:
13+
version:
14+
- '1'
15+
- 'nightly'
16+
os:
17+
- ubuntu-latest
18+
- macOS-latest
19+
- windows-latest
20+
arch:
21+
- x64
22+
steps:
23+
- uses: actions/checkout@v2
24+
- uses: julia-actions/setup-julia@latest
25+
with:
26+
version: ${{ matrix.version }}
27+
arch: ${{ matrix.arch }}
28+
- uses: julia-actions/julia-buildpkg@latest
29+
- uses: julia-actions/julia-runtest@latest
30+
- uses: julia-actions/julia-uploadcodecov@latest
31+
env:
32+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
33+
34+
35+
Skip:
36+
if: "contains(github.event.head_commit.message, '[skip ci]')"
37+
runs-on: ubuntu-latest
38+
steps:
39+
- name: Skip CI 🚫
40+
run: echo skip ci

.github/workflows/docs.yml

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Documentation
2+
3+
on:
4+
push:
5+
branches:
6+
- 'master'
7+
- 'release-'
8+
tags: '*'
9+
pull_request:
10+
11+
jobs:
12+
build:
13+
runs-on: ${{ matrix.os }}
14+
strategy:
15+
matrix:
16+
julia-version: [1.3.1]
17+
julia-arch: [x86]
18+
os: [ubuntu-latest]
19+
steps:
20+
- uses: actions/checkout@v2
21+
- uses: julia-actions/setup-julia@latest
22+
with:
23+
version: ${{ matrix.julia-version }}
24+
- name: Install dependencies
25+
run: julia --project=docs -e 'using Pkg; Pkg.instantiate()'
26+
- name: Build and deploy
27+
env:
28+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
30+
run: julia --project=docs --color=yes docs/make.jl

.travis.yml

-32
This file was deleted.

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ API for Matlab's language core functions
33

44
[![Dev Doc](https://img.shields.io/badge/docs-dev-blue.svg)](https://juliamatlab.github.io/MatLang/dev)
55
[![Project Status: Active – The project has reached a stable, usable state and is being actively developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active)
6-
[![Build Status](https://travis-ci.com/juliamatlab/MatLang.svg?branch=master)](https://travis-ci.com/juliamatlab/MatLang)
7-
[![Build status](https://ci.appveyor.com/api/projects/status/vempmfhwcyma2omm?svg=true)](https://ci.appveyor.com/project/aminya/matlang)
6+
![Build Status (Github Actions)](https://github.com/aminya/MatLang/workflows/CI/badge.svg)
7+
[![Test Coverage](https://codecov.io/gh/aminya/MatLang/branch/master/graph/badge.svg)](https://codecov.io/gh/aminya/MatLang)
88

99
# Documentation
1010
[![Dev Doc](https://img.shields.io/badge/docs-dev-blue.svg)](https://juliamatlab.github.io/MatLang/dev)

deps/SnoopCompile/example_script.jl

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Run the examples
2+
using MatLang
3+
examplePath = joinpath( dirname(dirname(@__DIR__)), "examples")
4+
include(joinpath(examplePath, "Language_Fundamentals", "usage_Entering_Commands.jl"))
5+
include(joinpath(examplePath, "Language_Fundamentals", "usage_Matrices_and_Arrays.jl"))
6+
include(joinpath(examplePath, "Language_Fundamentals", "Data_Types", "usage_Numeric_Types.jl"))

0 commit comments

Comments
 (0)