Skip to content

Commit

Permalink
ci: updated ci to latests versions
Browse files Browse the repository at this point in the history
  • Loading branch information
arthurfiorette committed Jun 20, 2023
1 parent b7347ce commit fe6b558
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 40 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Expand Up @@ -21,13 +21,13 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
fetch-depth: 0

- name: Cache cargo files
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docs.yml
Expand Up @@ -14,13 +14,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
fetch-depth: 0

- name: Cache cargo files
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
Expand Down
60 changes: 26 additions & 34 deletions .github/workflows/publish.yml
Expand Up @@ -13,13 +13,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
fetch-depth: 0

- name: Cache cargo files
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
Expand Down Expand Up @@ -51,14 +51,11 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout
with:
ref: ${{ github.head_ref }}
fetch-depth: 0

- name: Login to crates.io
run: cargo login

- name: Publish lexer to crates.io
run: cargo publish --package brainease_lexer

Expand All @@ -80,41 +77,31 @@ jobs:
attach:
needs: [test]
name: Attach binaries on latest release (${{ matrix.os }})

runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
binary_target: x86_64-unknown-linux-musl
toolchain: stable

- os: windows-latest
binary_target: x86_64-pc-windows-msvc
toolchain: stable-x86_64-pc-windows-msvc

- os: macos-latest
binary_target: x86_64-apple-darwin
toolchain: stable

- os: arm-latest
binary_target: armv7-unknown-linux-musleabihf
toolchain: stable-armv7-unknown-linux-musleabihf
target:
[
x86_64-unknown-linux-musl,
x86_64-pc-windows-msvc,
x86_64-apple-darwin,
armv7-unknown-linux-gnueabihf
]

steps:
- name: Install musl tools
if: matrix.os == 'ubuntu-latest'
run: sudo apt-get install musl-tools

- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout
with:
fetch-depth: 0

- name: Install musl tools
run: sudo apt-get install musl-tools

- name: Cache cargo files
uses: actions/cache@v2
uses: actions/cache
with:
path: |
~/.cargo/bin/
Expand All @@ -127,26 +114,31 @@ jobs:
- name: Install rust
uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.toolchain }}
toolchain: stable
profile: minimal
target: ${{ matrix.target }}
override: true

- name: Build binaries
run: cargo build --all --release
- name: Build target
uses: actions-rs/cargo@v1
with:
use-cross: true
command: build
args: --all --release --target ${{ matrix.target }}

- name: Zip binaries
uses: vimtor/action-zip@v1
with:
files:
README.md LICENSE target/release/${{ (matrix.os == 'windows-latest' &&
'brainz.exe') || 'brainz'}}
dest: brainease-${{ matrix.binary_target }}.zip
dest: brainease-${{ matrix.target }}.zip

- name: Upload Binaries
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: brainease-${{ matrix.binary_target }}.zip
file: brainease-${{ matrix.target }}.zip
file_glob: true
tag: ${{ github.ref }}
overwrite: true
9 changes: 7 additions & 2 deletions CHANGELOG.md
Expand Up @@ -4,9 +4,9 @@ All notable changes to this project will be documented in this file.

## [unreleased]

### Refactor
### Tag

- Removed pub mod tests
- V1.0.7

## [1.0.7] - 2023-06-20

Expand All @@ -20,6 +20,7 @@ All notable changes to this project will be documented in this file.

### Documentation

- Changelog
- Fixed cname
- Added pointer movement page
- Updated documentation page
Expand All @@ -37,6 +38,9 @@ All notable changes to this project will be documented in this file.

### Features

- Updated actions v3
- Updated actions v2
- Updated actions
- Tag v1.0.7
- Added arm version
- Updated dependencies
Expand Down Expand Up @@ -73,6 +77,7 @@ All notable changes to this project will be documented in this file.

### Refactor

- Removed pub mod tests
- Clippy and Eq imports
- Minor things
- Added cli descriptions
Expand Down

0 comments on commit fe6b558

Please sign in to comment.