Skip to content

Commit

Permalink
ci(deploy): release to crates.io
Browse files Browse the repository at this point in the history
  • Loading branch information
max-niederman committed Jun 19, 2022
1 parent d21a5f2 commit 2df82cb
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 112 deletions.
27 changes: 24 additions & 3 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ jobs:
steps:
- name: Setup | Checkout
uses: actions/checkout@v2

- name: Setup | Toolchain
uses: actions-rs/toolchain@v1
with:
Expand Down Expand Up @@ -100,6 +100,27 @@ jobs:
name: ${{ matrix.name }}
path: ${{ matrix.name }}

crates-io-release:
name: crates.io Release
runs-on: ubuntu-latest

steps:
- name: Setup | Checkout
uses: actions/checkout@v2

- name: Setup | Toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true

- name: Publish
uses: actions-rs/cargo@v1
with:
command: publish
args: --token ${{ secrets.CRATES_IO_TOKEN }}

github-release:
name: GitHub Release
needs: binaries
Expand All @@ -116,10 +137,10 @@ jobs:
run: for file in ttyper-*/ttyper-*; do openssl dgst -sha256 -r "$file" | awk '{print $1}' > "${file}.sha256"; done

- name: Publish
uses: marvinpinto/action-automatic-releases@latest
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
prerelease: false # TODO: Check tag to test for prereleases
prerelease: ${{ contains(github.ref_name, 'pre') }}
files: |
ttyper-*/ttyper-*
LICENSE.md
126 changes: 19 additions & 107 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "ttyper"
description = "Terminal-based typing test."
version = "0.4.3"
version = "1.0.0-pre.1"
readme = "README.md"
repository = "https://github.com/max-niederman/ttyper.git"
homepage = "https://github.com/max-niederman/ttyper"
Expand All @@ -17,7 +17,7 @@ rust-embed = "6.2"
toml = "0.5"

[dependencies.tui]
version = "0.17"
version = "0.18"
default-features = false
features = ["crossterm"]

Expand Down

0 comments on commit 2df82cb

Please sign in to comment.