Skip to content

Commit

Permalink
⬆️ rust-analyzer
Browse files Browse the repository at this point in the history
  • Loading branch information
lnicola committed Feb 13, 2023
2 parents 2008188 + c97aae3 commit c4a2f06
Show file tree
Hide file tree
Showing 321 changed files with 11,188 additions and 9,698 deletions.
10 changes: 0 additions & 10 deletions src/tools/rust-analyzer/.github/ISSUE_TEMPLATE/blank_issue.md

This file was deleted.

4 changes: 2 additions & 2 deletions src/tools/rust-analyzer/.github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name: Bug report
about: Create a bug report for rust-analyzer.
title: ''
labels: ''
labels: 'C-bug'
assignees: ''

---
Expand All @@ -22,4 +22,4 @@ Otherwise please try to provide information which will help us to fix the issue

**rustc version**: (eg. output of `rustc -V`)

**relevant settings**: (eg. client settings, or environment variables like `CARGO`, `RUSTUP_HOME` or `CARGO_HOME`)
**relevant settings**: (eg. client settings, or environment variables like `CARGO`, `RUSTC`, `RUSTUP_HOME` or `CARGO_HOME`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: Feature Request
about: Create a feature request for rust-analyzer.
title: ''
labels: 'C-feature'
assignees: ''

---
8 changes: 8 additions & 0 deletions src/tools/rust-analyzer/.github/ISSUE_TEMPLATE/question.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: Support Question
about: A question regarding functionality of rust-analyzer.
title: ''
labels: 'C-support'
assignees: ''

---
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: publish
name: autopublish
on:
workflow_dispatch: # We can add version input when 1.0 is released and scheduled releases are removed

Expand All @@ -25,7 +25,7 @@ jobs:
- name: Install cargo-workspaces
run: cargo install cargo-workspaces

- name: Release
- name: Publish Crates
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
PATCH: ${{ github.run_number }}
Expand Down
43 changes: 43 additions & 0 deletions src/tools/rust-analyzer/.github/workflows/fuzz.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Fuzz
on:
schedule:
# Once a week
- cron: '0 0 * * 0'
push:
paths:
- '.github/workflows/fuzz.yml'
# Allow manual trigger
workflow_dispatch:

env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
CI: 1
RUST_BACKTRACE: short
RUSTFLAGS: "-D warnings -W unreachable-pub -W bare-trait-objects"
RUSTUP_MAX_RETRIES: 10

jobs:
rust:
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event.action == 'workflow_dispatch' }}
name: Rust
runs-on: ubuntu-latest
env:
CC: deny_c

steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 1

- name: Install Rust toolchain
run: |
rustup install --profile minimal nightly
- name: Build fuzzers
run: |
cargo install cargo-fuzz
cd crates/syntax
cargo +nightly fuzz build
35 changes: 35 additions & 0 deletions src/tools/rust-analyzer/.github/workflows/publish-libs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: publish-libs
on:
workflow_dispatch:
push:
branches:
- main
paths:
- 'lib/**'

jobs:
publish-libs:
name: publish
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Install Rust toolchain
run: rustup update --no-self-update stable

- name: Install cargo-workspaces
run: cargo install cargo-workspaces

- name: Publish Crates
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
shell: bash
run: |
git config --global user.email "runner@gha.local"
git config --global user.name "Github Action"
# Remove r-a crates from the workspaces so we don't auto-publish them as well
sed -i 's/ "crates\/\*"//' ./Cargo.toml
cargo workspaces publish --yes --exact --from-git --no-git-commit --allow-dirty
7 changes: 7 additions & 0 deletions src/tools/rust-analyzer/.github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ jobs:
- os: windows-latest
target: x86_64-pc-windows-msvc
code-target: win32-x64
- os: windows-latest
target: i686-pc-windows-msvc
code-target: win32-ia32
- os: windows-latest
target: aarch64-pc-windows-msvc
code-target: win32-arm64
Expand Down Expand Up @@ -230,6 +233,10 @@ jobs:
with:
name: dist-x86_64-pc-windows-msvc
path: dist
- uses: actions/download-artifact@v1
with:
name: dist-i686-pc-windows-msvc
path: dist
- uses: actions/download-artifact@v1
with:
name: dist-aarch64-pc-windows-msvc
Expand Down
Loading

0 comments on commit c4a2f06

Please sign in to comment.