diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0b21969..4170f89 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,13 +7,13 @@ on: jobs: lint: runs-on: ubuntu-latest - steps: - uses: actions/checkout@v3 - uses: NTBBloodbath/selene-action@v1.0.0 with: token: ${{ secrets.GITHUB_TOKEN }} args: lua + docs: runs-on: ubuntu-latest if: ${{ github.ref == 'refs/heads/main' }} @@ -34,6 +34,7 @@ jobs: commit_user_name: "github-actions[bot]" commit_user_email: "github-actions[bot]@users.noreply.github.com" commit_author: "github-actions[bot] " + build: runs-on: ubuntu-latest if: ${{ github.ref == 'refs/heads/main' }} @@ -50,13 +51,6 @@ jobs: neovim: true version: stable - - name: Setup git - run: | - printf 'BUILD_BRANCH=bot/build/%s\n' ${GITHUB_REF#refs/heads/} >> $GITHUB_ENV - - - name: Checkout to build branch - run: git checkout -b ${BUILD_BRANCH} - - name: Run builder script run: | mkdir -p autoload/lightline/colorscheme colors/ lua/lualine extras @@ -76,13 +70,6 @@ jobs: steps: - uses: actions/checkout@v3 - - name: Setup git - run: | - printf 'STYLE_BRANCH=bot/style/%s\n' ${GITHUB_REF#refs/heads/} >> $GITHUB_ENV - - - name: Checkout to style branch - run: git checkout -b ${STYLE_BRANCH} - - uses: JohnnyMorganz/stylua-action@v2 with: version: latest diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml deleted file mode 100644 index b356470..0000000 --- a/.github/workflows/format.yml +++ /dev/null @@ -1,48 +0,0 @@ -name: Format -on: - push: - paths: - - 'lua/**.lua' - - '**.md' - branches: [main, dev] - -jobs: - format: - runs-on: ubuntu-latest - permissions: - contents: write - pull-requests: write - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - steps: - - uses: actions/checkout@v3 - - - name: Setup git - run: | - git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com" - git config --local user.name "github-actions[bot]" - printf 'STYLE_BRANCH=bot/style/%s\n' ${GITHUB_REF#refs/heads/} >> $GITHUB_ENV - - - name: Checkout to style branch - run: git checkout -b ${STYLE_BRANCH} - - - uses: JohnnyMorganz/stylua-action@v1 - with: - version: 0.15.1 - token: ${{ secrets.GITHUB_TOKEN }} - args: --config-path=.stylua.toml lua/ - - - uses: actions/setup-node@v3 - - name: Apply prettier - run: | - npm install -g prettier - prettier --write **/*.md - - - name: Create PR - run: | - if ! [[ -z $(git status -s) ]]; then - git add -u - git commit -m "chore: format" - git push --force https://${GITHUB_ACTOR}:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY} ${STYLE_BRANCH} - gh pr create --fill --base ${GITHUB_REF#refs/heads/} --head ${STYLE_BRANCH} || true - fi