Regenerate nvim config
This commit is contained in:
7
config/neovim/store/nvim-treesitter/.github/CODEOWNERS
vendored
Normal file
7
config/neovim/store/nvim-treesitter/.github/CODEOWNERS
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
/lua/nvim-treesitter/textobjects/ @theHamsta
|
||||
/lua/nvim-treesitter/incremental_selection.lua @theHamsta
|
||||
|
||||
/lua/nvim-treesitter/fold.lua @vigoux
|
||||
/lua/nvim-treesitter/highlight.lua @vigoux
|
||||
|
||||
/lua/nvim-treesitter/refactor/ @steelsojka
|
||||
2
config/neovim/store/nvim-treesitter/.github/FUNDING.yml
vendored
Normal file
2
config/neovim/store/nvim-treesitter/.github/FUNDING.yml
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
open_collective: "nvim-treesitter"
|
||||
github: "nvim-treesitter"
|
||||
58
config/neovim/store/nvim-treesitter/.github/ISSUE_TEMPLATE/bug_report.yml
vendored
Normal file
58
config/neovim/store/nvim-treesitter/.github/ISSUE_TEMPLATE/bug_report.yml
vendored
Normal file
@ -0,0 +1,58 @@
|
||||
name: Bug report
|
||||
description: Create a report to help us improve
|
||||
labels: [bug]
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
# Before reporting
|
||||
Please do the following steps before reporting an issue.
|
||||
|
||||
- I have updated my neovim version to latest _master_
|
||||
- I have updated my plugin to the latest version
|
||||
- I have run `:TSUpdate`
|
||||
- I have read the [troubleshooting section](https://github.com/nvim-treesitter/nvim-treesitter#troubleshooting)
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Describe the bug
|
||||
description: A clear and concise description of what the bug is.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: To Reproduce
|
||||
description: Steps to reproduce the behavior.
|
||||
placeholder: |
|
||||
1. Go to '...'
|
||||
2. Click on '....'
|
||||
3. Scroll down to '....'
|
||||
4. See error
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Expected behavior
|
||||
description: A clear and concise description of what you expected to happen.
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Output of `:checkhealth nvim-treesitter`
|
||||
render: markdown
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Output of `nvim --version`
|
||||
render: text
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Additional context
|
||||
description: Add any context about the problem here.
|
||||
19
config/neovim/store/nvim-treesitter/.github/ISSUE_TEMPLATE/feature_request.md
vendored
Normal file
19
config/neovim/store/nvim-treesitter/.github/ISSUE_TEMPLATE/feature_request.md
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest an idea for this project
|
||||
title: ""
|
||||
labels: enhancement
|
||||
assignees: ""
|
||||
---
|
||||
|
||||
**Is your feature request related to a problem? Please describe.**
|
||||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A clear and concise description of what you want to happen.
|
||||
|
||||
**Describe alternatives you've considered**
|
||||
A clear and concise description of any alternative solutions or features you've considered.
|
||||
|
||||
**Additional context**
|
||||
Add any other context or screenshots about the feature request here.
|
||||
98
config/neovim/store/nvim-treesitter/.github/ISSUE_TEMPLATE/highlighting_issue.yml
vendored
Normal file
98
config/neovim/store/nvim-treesitter/.github/ISSUE_TEMPLATE/highlighting_issue.yml
vendored
Normal file
@ -0,0 +1,98 @@
|
||||
name: Highlighting issue
|
||||
description: Missing or incorrect highlights or you want to change the way something is highlighted
|
||||
labels: [highlights]
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
# Before reporting
|
||||
Please perform the following steps before reporting an issue.
|
||||
- I have updated my neovim version to latest _master_.
|
||||
- I have updated my plugin to the latest version.
|
||||
- I have run `:TSUpdate`.
|
||||
- I have inspected the syntax tree using `:InspectTree` and made sure
|
||||
that no `ERROR` nodes are in the syntax tree. nvim-treesitter can not guarantee correct highlighting in the
|
||||
presence of `ERROR`s -- in this case, please report the bug directly at corresponding parser's repository. (You can find all repository URLs in [README.md](https://github.com/nvim-treesitter/nvim-treesitter#supported-languages).)
|
||||
- I have used `:Inspect` to inspect which highlight groups Neovim is using and that legacy syntax highlighting is not interfering (i.e., what you are observing is actual tree-sitter highlighting).
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Describe the highlighting problem
|
||||
description: A clear and concise description of what should be highlighted in a different way.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Example snippet that causes the problem
|
||||
description: Please provide an example snippet in plain text that causes the problem.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Tree-sitter parsing result
|
||||
description: |
|
||||
Please provide the output of `:InspectTree` (screenshot or plain text)
|
||||
with the following options enabled (pressing the key):
|
||||
- `I` (name of the parsed language)
|
||||
- `t` (toggle injected languages)
|
||||
- `a` (show anonymous nodes)
|
||||
placeholder: |
|
||||
This should look somehow like this:
|
||||
```
|
||||
preproc_ifdef [0, 0] - [4, 6] cpp
|
||||
"#ifdef" [0, 0] - [0, 6] cpp
|
||||
name: identifier [0, 7] - [0, 17] cpp
|
||||
preproc_def [1, 0] - [2, 0] cpp
|
||||
"#define" [1, 0] - [1, 7] cpp
|
||||
name: identifier [1, 8] - [1, 16] cpp
|
||||
value: preproc_arg [1, 16] - [1, 27] cpp
|
||||
"\n" [1, 27] - [2, 0] cpp
|
||||
alternative: preproc_else [2, 0] - [4, 0] cpp
|
||||
"#else" [2, 0] - [2, 5] cpp
|
||||
preproc_def [3, 0] - [4, 0] cpp
|
||||
"#define" [3, 0] - [3, 7] cpp
|
||||
name: identifier [3, 8] - [3, 16] cpp
|
||||
value: preproc_arg [3, 16] - [3, 29] cpp
|
||||
```
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Example screenshot
|
||||
description: |
|
||||
Please provide a screenshot of the current highlighting. Please also tell us the `:h colorscheme` you are using
|
||||
and how to install it. If applicable, you can also upload a screenshot with the contents of
|
||||
`:Inspect`.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Expected behavior
|
||||
description: |
|
||||
A clear and concise description of what you expect to be changed. You can provide screenshot of
|
||||
other editors or traditional Vim highlighting that don't show this problem or show a screenshot how
|
||||
nvim-treesitter highlighting would look like when a problematic query would be removed/altered.
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Output of `:checkhealth nvim-treesitter`
|
||||
render: markdown
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Output of `nvim --version`
|
||||
render: text
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Additional context
|
||||
description: Add any context about the problem here.
|
||||
50
config/neovim/store/nvim-treesitter/.github/workflows/lint.yml
vendored
Normal file
50
config/neovim/store/nvim-treesitter/.github/workflows/lint.yml
vendored
Normal file
@ -0,0 +1,50 @@
|
||||
name: Linting and style checking
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- "master"
|
||||
|
||||
jobs:
|
||||
luacheck:
|
||||
name: Luacheck
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Prepare
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install luarocks -y
|
||||
sudo luarocks install luacheck
|
||||
|
||||
- name: Run Luacheck
|
||||
run: luacheck .
|
||||
|
||||
stylua:
|
||||
name: StyLua
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Lint with stylua
|
||||
uses: JohnnyMorganz/stylua-action@v3
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
version: latest
|
||||
args: --check .
|
||||
|
||||
format-queries:
|
||||
name: Lint queries
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Prepare
|
||||
run: |
|
||||
wget https://github.com/neovim/neovim/releases/download/nightly/nvim-linux64.tar.gz
|
||||
tar -zxf nvim-linux64.tar.gz
|
||||
sudo ln -s "$PWD"/nvim-linux64/bin/nvim /usr/local/bin
|
||||
|
||||
- name: Lint
|
||||
run: |
|
||||
nvim -l scripts/format-queries.lua
|
||||
git diff --exit-code
|
||||
24
config/neovim/store/nvim-treesitter/.github/workflows/release.yml
vendored
Normal file
24
config/neovim/store/nvim-treesitter/.github/workflows/release.yml
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
name: "release"
|
||||
on:
|
||||
push:
|
||||
tags: # Will upload to luarocks.org
|
||||
- "*"
|
||||
pull_request: # Will test a local install without uploading to luarocks.org
|
||||
paths:
|
||||
- 'contrib/*.rockspec'
|
||||
- .github/workflows/release.yml
|
||||
|
||||
jobs:
|
||||
luarocks-upload:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: nvim-neorocks/luarocks-tag-release@v5
|
||||
env:
|
||||
LUAROCKS_API_KEY: ${{ secrets.LUAROCKS_API_KEY }}
|
||||
with:
|
||||
name: nvim-treesitter
|
||||
detailed_description: |
|
||||
The goal of nvim-treesitter is both to provide a simple and easy way to use the interface for tree-sitter in Neovim
|
||||
and to provide some basic functionality such as highlighting based on it.
|
||||
template: contrib/nvim-treesitter-luarocks.template
|
||||
88
config/neovim/store/nvim-treesitter/.github/workflows/test-queries.yml
vendored
Normal file
88
config/neovim/store/nvim-treesitter/.github/workflows/test-queries.yml
vendored
Normal file
@ -0,0 +1,88 @@
|
||||
name: Test queries
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- "master"
|
||||
pull_request:
|
||||
branches:
|
||||
- "master"
|
||||
|
||||
# Cancel any in-progress CI runs for a PR if it is updated
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
|
||||
cancel-in-progress: true
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
jobs:
|
||||
check_compilation:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ubuntu-latest, windows-latest, macos-14]
|
||||
cc: [gcc, clang]
|
||||
nvim_tag: [stable]
|
||||
exclude:
|
||||
- os: ubuntu-latest
|
||||
cc: clang
|
||||
nvim_tag: stable
|
||||
|
||||
- os: macos-14
|
||||
cc: gcc
|
||||
nvim_tag: stable
|
||||
|
||||
- os: windows-latest
|
||||
cc: clang
|
||||
nvim_tag: stable
|
||||
|
||||
include:
|
||||
- os: windows-latest
|
||||
cc: cl
|
||||
nvim_tag: nightly
|
||||
|
||||
- os: ubuntu-latest
|
||||
cc: gcc
|
||||
nvim_tag: nightly
|
||||
|
||||
name: Parser compilation
|
||||
runs-on: ${{ matrix.os }}
|
||||
env:
|
||||
CC: ${{ matrix.cc }}
|
||||
NVIM: ${{ matrix.os == 'windows-latest' && 'nvim-win64\\bin\\nvim.exe' || 'nvim' }}
|
||||
ALLOWED_INSTALLATION_FAILURES: ${{ matrix.os == 'windows-latest' && 'rnoweb' }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: tree-sitter/setup-action/cli@v1
|
||||
- uses: ilammy/msvc-dev-cmd@v1
|
||||
|
||||
- name: Install and prepare Neovim
|
||||
env:
|
||||
NVIM_TAG: ${{ matrix.nvim_tag }}
|
||||
run: |
|
||||
bash ./scripts/ci-install.sh
|
||||
|
||||
- name: Setup Parsers Cache
|
||||
id: parsers-cache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
./parser/
|
||||
~/AppData/Local/nvim/pack/nvim-treesitter/start/nvim-treesitter/parser/
|
||||
key: parsers-${{ join(matrix.*, '-') }}-${{ hashFiles(
|
||||
'./lockfile.json',
|
||||
'./lua/nvim-treesitter/install.lua',
|
||||
'./lua/nvim-treesitter/parsers.lua',
|
||||
'./lua/nvim-treesitter/shell_command_selectors.lua') }}
|
||||
|
||||
- name: Compile parsers
|
||||
run: $NVIM --headless -c "lua require'nvim-treesitter.install'.prefer_git=false" -c "TSInstallSync all" -c "q"
|
||||
|
||||
- name: Post compile Windows
|
||||
if: runner.os == 'Windows'
|
||||
run: cp -r ~/AppData/Local/nvim/pack/nvim-treesitter/start/nvim-treesitter/parser/* parser
|
||||
|
||||
- name: Check query files
|
||||
run: $NVIM -l scripts/check-queries.lua
|
||||
65
config/neovim/store/nvim-treesitter/.github/workflows/tests.yml
vendored
Normal file
65
config/neovim/store/nvim-treesitter/.github/workflows/tests.yml
vendored
Normal file
@ -0,0 +1,65 @@
|
||||
name: Tests
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- "master"
|
||||
pull_request:
|
||||
branches:
|
||||
- "master"
|
||||
|
||||
# Cancel any in-progress CI runs for a PR if it is updated
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
check_compilation:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ubuntu-latest]
|
||||
cc: [gcc]
|
||||
|
||||
name: Run tests
|
||||
runs-on: ${{ matrix.os }}
|
||||
env:
|
||||
CC: ${{ matrix.cc }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: tree-sitter/setup-action/cli@v1
|
||||
|
||||
- name: Test Dependencies
|
||||
run: |
|
||||
mkdir -p ~/.local/share/nvim/site/pack/plenary.nvim/start
|
||||
cd ~/.local/share/nvim/site/pack/plenary.nvim/start
|
||||
git clone https://github.com/nvim-lua/plenary.nvim
|
||||
curl -L https://github.com/theHamsta/highlight-assertions/releases/download/v0.1.6/highlight-assertions_v0.1.6_x86_64-unknown-linux-gnu.tar.gz | tar -xz
|
||||
cp highlight-assertions /usr/local/bin
|
||||
|
||||
- name: Install and prepare Neovim
|
||||
env:
|
||||
NVIM_TAG: stable
|
||||
run: |
|
||||
bash ./scripts/ci-install.sh
|
||||
|
||||
- name: Setup Parsers Cache
|
||||
id: parsers-cache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
./parser/
|
||||
~/AppData/Local/nvim/pack/nvim-treesitter/start/nvim-treesitter/parser/
|
||||
key: parsers-${{ join(matrix.*, '-') }}-${{ hashFiles(
|
||||
'./lockfile.json',
|
||||
'./lua/nvim-treesitter/install.lua',
|
||||
'./lua/nvim-treesitter/parsers.lua',
|
||||
'./lua/nvim-treesitter/shell_selectors.lua') }}
|
||||
|
||||
- name: Compile parsers Unix like
|
||||
if: ${{ runner.os != 'Windows' && steps.parsers-cache.outputs.cache-hit != 'true' }}
|
||||
run: |
|
||||
nvim --headless -c "TSInstallSync all" -c "q"
|
||||
|
||||
- name: Tests
|
||||
run: PATH=/usr/local/bin:$PATH ./scripts/run_tests.sh
|
||||
58
config/neovim/store/nvim-treesitter/.github/workflows/update-lockfile.yml
vendored
Normal file
58
config/neovim/store/nvim-treesitter/.github/workflows/update-lockfile.yml
vendored
Normal file
@ -0,0 +1,58 @@
|
||||
name: Update lockfile
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "30 6 * * *"
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
update-lockfile:
|
||||
name: Update lockfile
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
ref: master
|
||||
|
||||
- uses: actions/create-github-app-token@v1
|
||||
id: app-token
|
||||
with:
|
||||
app-id: ${{ vars.TOKEN_ID }}
|
||||
private-key: ${{ secrets.TOKEN_PRIVATE_KEY }}
|
||||
|
||||
- name: Prepare
|
||||
env:
|
||||
NVIM_TAG: stable
|
||||
run: |
|
||||
wget https://github.com/josephburnett/jd/releases/download/v1.7.1/jd-amd64-linux
|
||||
mv jd-amd64-linux /tmp/jd
|
||||
chmod +x /tmp/jd
|
||||
bash scripts/ci-install.sh
|
||||
|
||||
- name: Update parsers
|
||||
env:
|
||||
SKIP_LOCKFILE_UPDATE_FOR_LANGS: ""
|
||||
run: |
|
||||
cp lockfile.json /tmp/old_lockfile.json
|
||||
nvim -l scripts/write-lockfile.lua
|
||||
# Pretty print
|
||||
cp lockfile.json /tmp/lockfile.json
|
||||
cat /tmp/lockfile.json | jq --sort-keys > lockfile.json
|
||||
UPDATED_PARSERS=$(/tmp/jd -f merge /tmp/old_lockfile.json lockfile.json | jq -r 'keys | join(", ")')
|
||||
echo "UPDATED_PARSERS=$UPDATED_PARSERS" >> $GITHUB_ENV
|
||||
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v6
|
||||
with:
|
||||
token: ${{ steps.app-token.outputs.token }}
|
||||
author: "nvim-treesitter-bot[bot] <157957100+nvim-treesitter-bot[bot]@users.noreply.github.com>"
|
||||
commit-message: "bot(lockfile): update ${{ env.UPDATED_PARSERS }}"
|
||||
title: "Update lockfile.json: ${{ env.UPDATED_PARSERS }}"
|
||||
body: "[beep boop](https://github.com/peter-evans/create-pull-request)"
|
||||
branch: update-lockfile-pr
|
||||
base: ${{ github.head_ref }}
|
||||
|
||||
- name: Enable Pull Request Automerge
|
||||
env:
|
||||
GH_TOKEN: ${{ steps.app-token.outputs.token }}
|
||||
run: gh pr merge --rebase --auto update-lockfile-pr
|
||||
46
config/neovim/store/nvim-treesitter/.github/workflows/update-readme.yml
vendored
Normal file
46
config/neovim/store/nvim-treesitter/.github/workflows/update-readme.yml
vendored
Normal file
@ -0,0 +1,46 @@
|
||||
name: Update README
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
update-readme:
|
||||
name: Update README
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: actions/create-github-app-token@v1
|
||||
id: app-token
|
||||
with:
|
||||
app-id: ${{ vars.TOKEN_ID }}
|
||||
private-key: ${{ secrets.TOKEN_PRIVATE_KEY }}
|
||||
|
||||
- name: Prepare
|
||||
env:
|
||||
NVIM_TAG: stable
|
||||
run: |
|
||||
bash ./scripts/ci-install.sh
|
||||
|
||||
- name: Check README
|
||||
run: |
|
||||
nvim -l scripts/update-readme.lua || echo 'Needs update'
|
||||
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v6
|
||||
with:
|
||||
token: ${{ steps.app-token.outputs.token }}
|
||||
author: "nvim-treesitter-bot[bot] <157957100+nvim-treesitter-bot[bot]@users.noreply.github.com>"
|
||||
commit-message: "bot(readme): update"
|
||||
title: Update README
|
||||
body: "[beep boop](https://github.com/peter-evans/create-pull-request)"
|
||||
branch: update-readme-pr
|
||||
base: ${{ github.head_ref }}
|
||||
|
||||
- name: Enable Pull Request Automerge
|
||||
env:
|
||||
GH_TOKEN: ${{ steps.app-token.outputs.token }}
|
||||
run: gh pr merge --rebase --auto update-readme-pr
|
||||
Reference in New Issue
Block a user