Add flutter lookup command configuration option #53
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will build a golang project | |
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go | |
name: Go | |
on: | |
push: | |
branches: [ "main" ] | |
paths: | |
- ".github/workflows/measure-vim-startuptime.yml" | |
- "dot_config/nvim/init.vim" | |
- "dot_config/nvim/dein/*" | |
pull_request: | |
branches: [ "main" ] | |
paths: | |
- ".github/workflows/measure-vim-startuptime.yml" | |
- "dot_config/nvim/init.vim" | |
- "dot_config/nvim/dein/*" | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Setup Go | |
uses: actions/setup-go@v3 | |
with: | |
go-version: 1.19 | |
- name: Setup vim-startuptime | |
run: go install github.com/rhysd/vim-startuptime@latest | |
- name: Setup Deno | |
uses: denoland/setup-deno@v1 | |
with: | |
deno-version: v1.x | |
- name: Setup Chezmoi | |
run: sh -c "$(curl -fsLS get.chezmoi.io)" -- init --apply ${GITHUB_REPOSITORY%/*} | |
- name: Setup Neovim | |
uses: MunifTanjim/setup-neovim-action@v1 | |
with: | |
tag: nightly | |
- name: Setup Neovim Plugins | |
run: nvim -c "au VimEnter * cal dein#recache_runtimepath() | q" | |
- name: Measure vim-startuptime & Create tweet | |
run: | | |
EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64) | |
echo "TWEET<<$EOF" >> "$GITHUB_ENV" | |
echo "Update .config/nvim:" >> "$GITHUB_ENV" | |
RESULT=$(vim-startuptime -vimpath nvim) | |
echo "${RESULT}" | head -n 6 | awk '{print "> " $0}' >> "$GITHUB_ENV" | |
echo >> "$GITHUB_ENV" | |
echo "View latest Neovim Configuration → https://github.com/gw31415/dotfiles/tree/main/dot_config/nvim" >> "$GITHUB_ENV" | |
echo "#Vim #Neovim #dotfiles" >> "$GITHUB_ENV" | |
echo "$EOF" >> "$GITHUB_ENV" | |
# - name: Post tweet | |
# uses: InfraWay/tweet-action@v1.0.1 | |
# with: | |
# status: ${{ env.TWEET }} | |
# api_key: ${{ secrets.TWITTER_API_KEY }} | |
# api_key_secret: ${{ secrets.TWITTER_API_KEY_SECRET }} | |
# access_token: ${{ secrets.TWITTER_ACCESS_TOKEN }} | |
# access_token_secret: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }} | |
- name: Send toot to Mastodon | |
id: mastodon | |
uses: cbrgm/mastodon-github-action@v1.0.3 | |
with: | |
message: ${{ env.TWEET }} | |
visibility: "public" # default: public | |
env: | |
MASTODON_URL: ${{ secrets.PGRIT_URL }} | |
MASTODON_ACCESS_TOKEN: ${{ secrets.PGRIT_ACCESS_TOKEN }} |