Skip to content

Commit

Permalink
ci: enable back disabled actions
Browse files Browse the repository at this point in the history
  • Loading branch information
plusvic committed Oct 16, 2024
1 parent 418876a commit 7ca7a64
Showing 1 changed file with 51 additions and 51 deletions.
102 changes: 51 additions & 51 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,14 @@ jobs:
with:
toolchain: stable

#- name: Check version number
# shell: bash
# run: |
# set -ex
# version=`cargo pkgid --manifest-path lib/Cargo.toml | cut -d "@" -f2`
# if [ "${{ github.ref_name }}" != "v$version" ]; then
# exit 1
# fi
- name: Check version number
shell: bash
run: |
set -ex
version=`cargo pkgid --manifest-path lib/Cargo.toml | cut -d "@" -f2`
if [ "${{ github.ref_name }}" != "v$version" ]; then
exit 1
fi
- run: rustup target add ${{ matrix.target }}

Expand Down Expand Up @@ -205,46 +205,46 @@ jobs:
draft: true
files: yr-*/yara-x-*

# publish-crate:
# needs: [ publish ]
# runs-on: ubuntu-latest
# steps:
# - name: Checkout sources
# uses: actions/checkout@v4
#
# - name: Publish crate
# env:
# # Don't re-generate the files `modules.rs` and `add_modules.rs`, use
# # the ones in the repository. These files can't be regenerated because
# # `cargo publish` checks that the repository doesn't change during
# # the build. See: https://github.com/rust-lang/cargo/pull/5584
# YRX_REGENERATE_MODULES_RS: "no"
# run: |
# cargo login ${{ secrets.CRATES_IO_API_TOKEN }}
# cargo publish -p yara-x-macros
# cargo publish -p yara-x-proto
# cargo publish -p yara-x-proto-yaml
# cargo publish -p yara-x-parser
# cargo publish -p yara-x
#
# publish-py:
# needs: [ build-py ]
# runs-on: ubuntu-latest
# environment:
# name: pypi
# url: https://pypi.org/p/yara-x
# permissions:
# id-token: write
# steps:
# - name: Download artifacts
# uses: actions/download-artifact@v4
# with:
# pattern: pypi-*
# merge-multiple: true
# path: dist
#
# - name: Publish package distributions to PyPI
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# #repository-url: https://test.pypi.org/legacy/
# skip-existing: true
publish-crate:
needs: [ publish ]
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4

- name: Publish crate
env:
# Don't re-generate the files `modules.rs` and `add_modules.rs`, use
# the ones in the repository. These files can't be regenerated because
# `cargo publish` checks that the repository doesn't change during
# the build. See: https://github.com/rust-lang/cargo/pull/5584
YRX_REGENERATE_MODULES_RS: "no"
run: |
cargo login ${{ secrets.CRATES_IO_API_TOKEN }}
cargo publish -p yara-x-macros
cargo publish -p yara-x-proto
cargo publish -p yara-x-proto-yaml
cargo publish -p yara-x-parser
cargo publish -p yara-x
publish-py:
needs: [ build-py ]
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/yara-x
permissions:
id-token: write
steps:
- name: Download artifacts
uses: actions/download-artifact@v4
with:
pattern: pypi-*
merge-multiple: true
path: dist

- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
#repository-url: https://test.pypi.org/legacy/
skip-existing: true

0 comments on commit 7ca7a64

Please sign in to comment.