mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-08 10:51:15 -03:00
Check license of dependencies in CI
This commit is contained in:
17
.github/workflows/lint-dependencies.yml
vendored
Normal file
17
.github/workflows/lint-dependencies.yml
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
name: CI
|
||||
on:
|
||||
pull_request:
|
||||
paths:
|
||||
- 'Cargo.lock'
|
||||
- '**/Cargo.toml'
|
||||
- 'deny.toml'
|
||||
jobs:
|
||||
cargo-deny:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: EmbarkStudios/cargo-deny-action@v2
|
||||
with:
|
||||
command: check licenses
|
||||
arguments: --all-features --locked --exclude-dev
|
||||
rust-version: 1.91 # updatecli.d/rust.yml
|
||||
@@ -6,6 +6,9 @@ members = ["crates/*"]
|
||||
rust-version = "1.85"
|
||||
edition = "2024"
|
||||
repository = "https://github.com/fish-shell/fish-shell"
|
||||
# see doc_src/license.rst for details
|
||||
# don't forget to update COPYING and debian/copyright too
|
||||
license = "GPL-2.0-only AND LGPL-2.0-or-later AND MIT AND PSF-2.0"
|
||||
|
||||
[workspace.dependencies]
|
||||
bitflags = "2.5.0"
|
||||
@@ -74,9 +77,7 @@ version = "4.2.1-snapshot"
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
default-run = "fish"
|
||||
# see doc_src/license.rst for details
|
||||
# don't forget to update COPYING and debian/copyright too
|
||||
license = "GPL-2.0-only AND LGPL-2.0-or-later AND MIT AND PSF-2.0"
|
||||
license.workspace = true
|
||||
homepage = "https://fishshell.com"
|
||||
readme = "README.rst"
|
||||
|
||||
|
||||
@@ -70,6 +70,9 @@ template_file=$(mktemp)
|
||||
cargo build --workspace --all-targets --features=gettext-extract
|
||||
)
|
||||
if $lint; then
|
||||
if command -v cargo-deny >/dev/null; then
|
||||
cargo deny --all-features --locked --exclude-dev check licenses
|
||||
fi
|
||||
PATH="$build_dir:$PATH" "$workspace_root/build_tools/style.fish" --all --check
|
||||
for features in "" --no-default-features; do
|
||||
cargo clippy --workspace --all-targets $features
|
||||
|
||||
@@ -4,6 +4,7 @@ edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
version = "0.0.0"
|
||||
repository.workspace = true
|
||||
license.workspace = true
|
||||
|
||||
[dependencies]
|
||||
rsconf.workspace = true
|
||||
|
||||
@@ -4,6 +4,7 @@ edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
version = "0.0.0"
|
||||
repository.workspace = true
|
||||
license.workspace = true
|
||||
|
||||
[build-dependencies]
|
||||
fish-build-helper.workspace = true
|
||||
|
||||
@@ -4,6 +4,7 @@ edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
version = "0.0.0"
|
||||
repository.workspace = true
|
||||
license.workspace = true
|
||||
description = "proc-macro for extracting strings for gettext translation"
|
||||
|
||||
[lib]
|
||||
|
||||
@@ -4,6 +4,7 @@ edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
version = "0.0.0"
|
||||
repository.workspace = true
|
||||
license.workspace = true
|
||||
|
||||
[dependencies]
|
||||
phf.workspace = true
|
||||
|
||||
@@ -4,6 +4,7 @@ edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
version = "0.0.0"
|
||||
repository.workspace = true
|
||||
license.workspace = true
|
||||
|
||||
[lints]
|
||||
workspace = true
|
||||
|
||||
@@ -4,6 +4,7 @@ edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
version = "0.0.0"
|
||||
repository.workspace = true
|
||||
license.workspace = true
|
||||
|
||||
[dependencies]
|
||||
nix = { workspace = true, features = ["fs", "feature"] }
|
||||
|
||||
@@ -29,6 +29,14 @@ targets:
|
||||
file: .github/actions/rust-toolchain/action.yml
|
||||
matchpattern: '\(stable\) echo \d+\.\d+ ;;.*'
|
||||
replacepattern: '(stable) echo {{ source "rust_stable_version" }} ;; # updatecli.d/rust.yml'
|
||||
update_rust_stable2:
|
||||
name: "Update Rust stable #2"
|
||||
sourceid: rust_stable_version
|
||||
kind: file
|
||||
spec:
|
||||
file: .github/workflows/lint-dependencies.yml
|
||||
matchpattern: 'rust-version: \d+\.\d+\b.*'
|
||||
replacepattern: 'rust-version: {{ source "rust_stable_version" }} # updatecli.d/rust.yml'
|
||||
update_msrv:
|
||||
name: "Update MSRV"
|
||||
sourceid: rust_stable_version
|
||||
|
||||
Reference in New Issue
Block a user