Skip to content

Commit

Permalink
Fools release
Browse files Browse the repository at this point in the history
  • Loading branch information
mbrav committed Apr 1, 2023
1 parent db0fdd7 commit c061689
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 0 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Release

on:
push:
tags:
- "*"

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Cache Build
id: cache-build
uses: actions/cache@v3
with:
path: src/target
key: ${{ runner.os }}-build

- name: Cargo Test
run: |
cargo test --release
# - name: Cargo Clippy
# run: |
# cargo clippy --release -- -W clippy::pedantic -W clippy::nursery -W clippy::unwrap_used

- name: Cargo Build Binary
run: |
cargo build --release
chmod +x target/release/git-raider
- name: Optimize Binary with UPX
run: |
upx --best --lzma target/release/git-raider
- name: Package Binary
run: |
toolchain=$(rustup toolchain list | awk '{print $1;}')
tar_name="git-raider_${{ github.ref_name }}-$toolchain"
tar -cvzf target/release/$tar_name.tar.gz target/release/git-raider
- name: Release
uses: docker://antonyurchenko/git-release:v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHANGELOG_FILE: CHANGELOG.md
with:
args: |
target/release/*.tar.gz
23 changes: 23 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.0.1] - 2023-04-01

### Added

- Add project

### Removed

- 'None

### Fixed

- 'None

<!-- [0.1.1]: https://github.com/mbrav/git_raider/compare/0.0.1...0.0.2 -->
[0.0.1]: https://github.com/mbrav/git_raider/releases/tag/0.0.1

0 comments on commit c061689

Please sign in to comment.