Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 11 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ jobs:
runs-on: ubuntu-latest

strategy:
matrix: { rust: ["stable", "nightly"] } # "1.67.0",
matrix: { rust: [stable, nightly] } # "1.67.0",

steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with: { toolchain: "${{ matrix.rust }}" }
with: { toolchain: '${{ matrix.rust }}' }

- name: Run cargo check for codespan
run: cargo check
Expand All @@ -36,7 +36,7 @@ jobs:

strategy:
fail-fast: false
matrix: { rust: ["stable", "nightly"] }
matrix: { rust: [stable, nightly] }

steps:
- uses: actions/checkout@v4
Expand All @@ -63,17 +63,18 @@ jobs:

strategy:
fail-fast: false
matrix: { rust: ["stable"] }
matrix: { rust: [stable] }

steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with: { toolchain: '${{ matrix.rust }}', components: 'rustfmt' }
with: { toolchain: '${{ matrix.rust }}', components: rustfmt }

- name: Run cargo fmt
run: cargo fmt --all -- --check

- uses: kaleidawave/release-downloader@improvements
env: { GH_TOKEN: '${{ env.GH_TOKEN }}' }
with: { items: 'kaleidawave/simple-toml-parser@canary[format]' }

- name: Check 'Cargo.toml' formatting
Expand All @@ -88,7 +89,7 @@ jobs:

strategy:
fail-fast: false
matrix: { rust: ["stable"] }
matrix: { rust: [stable] }

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -131,14 +132,15 @@ jobs:

- name: Checkout repository
uses: actions/checkout@v4
with: { repository: "${{ matrix.repository }}" }
with: { repository: '${{ matrix.repository }}' }

- name: Run check that it works
run: cargo locate-project
working-directory: ${{ matrix.path }}

- name: Update dependency to ${{ github.repository }} on ${{ github.head_ref }}
run: cargo add codespan-reporting --git https://github.com/${{ github.repository }} --branch ${{ github.head_ref }}
run: |
cargo add codespan-reporting --git https://github.com/${{ github.repository }} --branch ${{ github.head_ref }}
working-directory: ${{ matrix.path }}

- name: Run cargo tree
Expand All @@ -162,6 +164,7 @@ jobs:

- uses: kaleidawave/release-downloader@improvements
if: steps.changes.outputs.manifests == 'true'
env: { GH_TOKEN: '${{ env.GH_TOKEN }}' }
with: { items: 'kaleidawave/crates-release-gh-action@assets[crates-release]' }

- name: Check that it will publish to crates.io
Expand Down
12 changes: 7 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,17 @@ jobs:
contents: write

steps:
- uses: actions/checkout@v4
- uses: rust-lang/crates-io-auth-action@v1
id: auth
- id: checkout
uses: actions/checkout@v4

- id: auth
uses: rust-lang/crates-io-auth-action@v1

- name: Crates publish
uses: kaleidawave/crates-release-gh-action@improvements
id: release
with:
version: codespan=${{ github.event.inputs.version }},codespan-reporting=${{ github.event.inputs.version }},codespan-lsp=${{ github.event.inputs.version }}
version: ${{ github.event.inputs.version }}
crates-token: ${{ steps.auth.outputs.token }}

- name: Push updated Cargo.toml
Expand All @@ -38,4 +40,4 @@ jobs:
echo '${{ steps.release.outputs.new-versions }}' | jq -r '.[]' | while read -r update; do
git tag "release/$update"
done
git push --tags origin main
git push --tags origin ${{ steps.checkout.outputs.ref }}
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ members = [
"./codespan-lsp"
]
resolver = "2"
metadata.version_sync = true

[workspace.lints.clippy]
all = { level = "deny", priority = -1 }
Expand Down
2 changes: 2 additions & 0 deletions codespan-lsp/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ description = "Conversions between codespan types and Language Server Protocol t
homepage = "https://github.com/brendanzab/codespan"
repository = "https://github.com/brendanzab/codespan"
documentation = "https://docs.rs/codespan-lsp"
categories = ["compilers", "encoding"]
keywords = ["lsp", "codespan"]
edition = "2021"
rust-version = "1.67"

Expand Down
4 changes: 3 additions & 1 deletion codespan-reporting/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ description = "Beautiful diagnostic reporting for text-based programming languag
homepage = "https://github.com/brendanzab/codespan"
repository = "https://github.com/brendanzab/codespan"
documentation = "https://docs.rs/codespan-reporting"
categories = ["compilers", "command-line-interface"]
keywords = ["diagnostic-reporting"]
exclude = ["assets/**"]
edition = "2021"
rust-version = "1.67"
Expand All @@ -18,10 +20,10 @@ termcolor = { version = "1.0.4", optional = true }
unicode-width = ">=0.1,<0.3"

[dev-dependencies]
pico-args = "0.5.0"
anyhow = "1"
insta = "1.6.3"
peg = "0.7"
pico-args = "0.5.0"
rustyline = "6"
unindent = "0.1"

Expand Down
2 changes: 2 additions & 0 deletions codespan/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ description = "Data structures for tracking locations in source code"
homepage = "https://github.com/brendanzab/codespan"
repository = "https://github.com/brendanzab/codespan"
documentation = "https://docs.rs/codespan"
categories = ["compilers", "encoding"]
keywords = ["source-location", "serialization", "structures", "diagnostics", "tracking"]
edition = "2021"
rust-version = "1.67"

Expand Down