Skip to content

Commit

Permalink
Merge pull request #8 from Ant0wan/new
Browse files Browse the repository at this point in the history
New
  • Loading branch information
Ant0wan authored Jun 4, 2023
2 parents ba66d63 + 4fc5cc1 commit 674adab
Show file tree
Hide file tree
Showing 16 changed files with 21 additions and 36 deletions.
20 changes: 16 additions & 4 deletions .github/workflows/shellcheck.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,25 @@
name: Shellcheck

on: push

name: "Shellcheck"
permissions: {}

jobs:
shellcheck:
name: Shellcheck
strategy:
matrix:
include:
- dir: ./tools
options: -s bash -e SC1090
- dir: ./bashrc.d
options: -s sh -e SC214
- dir: ./init.sh
options: -s sh
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@master
- uses: ludeeus/action-shellcheck@master
with:
scandir: ${{ matrix.dir }}
env:
SHELLCHECK_OPTS: ${{ matrix.options }}
File renamed without changes.
1 change: 0 additions & 1 deletion config/bashrc.d/bash → bashrc.d/bash
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

eval "$(oh-my-posh init bash --config ~/.theme.omp.json)"

alias env='env|sort'
alias g='grep -arn --exclude-dir=.terraform*'
alias ls='ls --color=always'
alias vi='vim'
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
27 changes: 0 additions & 27 deletions config/bashrc

This file was deleted.

8 changes: 4 additions & 4 deletions init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ if ! [ -x "$(command -v jq)" ]; then
exit 1
fi

githubsource="https://raw.githubusercontent.com/Ant0wan/config-and-tools/master/config/"
githubsource="https://raw.githubusercontent.com/Ant0wan/config-and-tools/main/config/"

sudo dnf install https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-"$(rpm -E %fedora)".noarch.rpm -y
sudo dnf update -y
Expand All @@ -18,7 +18,6 @@ sudo chmod +x /usr/local/bin/oh-my-posh
oh-my-posh font install Meslo
oh-my-posh get shell
wget "${githubsource}theme.omp.json" -O "$HOME"/.theme.omp.json
wget "${githubsource}bashrc" -O "$HOME"/.bashrc
mkdir -p "$HOME"/.bashrc.d/

wget "${githubsource}gitconfig" -O "$HOME"/.gitconfig
Expand Down Expand Up @@ -56,10 +55,11 @@ sudo systemctl restart sshd

for key in $(bw get item gpg | jq -r '.fields[] | @base64'); do
_jq '.value' | base64 --decode >"$(_jq '.name')"
export SIGNING_KEY+=("$(gpg --import "$(_jq '.name')" |& head -n 1 | grep -Eo '[0-9A-Z]{16}+')")
SIGNING_KEY="${SIGNING_KEY:+$SIGNING_KEY }$(gpg --import "$(_jq '.name')" 2>&1 | head -n 1 | grep -Eo '[0-9A-Z]{16}+')"
export SIGNING_KEY
rm "$(_jq '.name')"
done
sed -i "s/{{signing_key}}/${SIGNING_KEY[0]}/g" "$HOME"/.gitconfig
sed -i "s/{{signing_key}}/${SIGNING_KEY%% *}/g" "$HOME"/.gitconfig

rm -rf "$HOME"/.vim
git clone [email protected]:Ant0wan/vim-plugin.git "$HOME"/.vim/
Expand Down
1 change: 1 addition & 0 deletions tools/rust.install.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/usr/bin/env bash
set -o errexit
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --profile complete -y --no-modify-path
"$(which cargo)" install cargo-watch cargo-audit
pushd "$(git rev-parse --show-toplevel)" || exit 1
cp config/bashrc.d/rust "$HOME"/.bashrc.d/rust
popd || exit 1

0 comments on commit 674adab

Please sign in to comment.