diff options
| author | Thomas Schmucker <ts@its1.de> | 2026-08-12 09:22:12 +0200 |
|---|---|---|
| committer | Thomas Schmucker <ts@its1.de> | 2026-08-12 09:22:12 +0200 |
| commit | 189d244d36d4ebb2189b698adb21f51cf1c4176a (patch) | |
| tree | 3a6a9847dafabea051997b1a9cbc124a242ec1d3 /bootstrap/neovim-dict.sh | |
| parent | 6e5882a2fd02d30206ab9ca8aa5847b8ea09196c (diff) | |
| download | dotfiles-189d244d36d4ebb2189b698adb21f51cf1c4176a.tar.gz dotfiles-189d244d36d4ebb2189b698adb21f51cf1c4176a.tar.bz2 dotfiles-189d244d36d4ebb2189b698adb21f51cf1c4176a.zip | |
Revert "Normalize line endings"
This reverts commit 6e5882a2fd02d30206ab9ca8aa5847b8ea09196c.
Diffstat (limited to 'bootstrap/neovim-dict.sh')
| -rwxr-xr-x | bootstrap/neovim-dict.sh | 88 |
1 files changed, 44 insertions, 44 deletions
diff --git a/bootstrap/neovim-dict.sh b/bootstrap/neovim-dict.sh index ee51db7..77a7db8 100755 --- a/bootstrap/neovim-dict.sh +++ b/bootstrap/neovim-dict.sh | |||
| @@ -1,44 +1,44 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | set -eu | 2 | set -eu |
| 3 | 3 | ||
| 4 | SPELL_DIR="$HOME/.local/share/nvim/site/spell" | 4 | SPELL_DIR="$HOME/.local/share/nvim/site/spell" |
| 5 | mkdir -p "$SPELL_DIR" | 5 | mkdir -p "$SPELL_DIR" |
| 6 | 6 | ||
| 7 | cd "$SPELL_DIR" | 7 | cd "$SPELL_DIR" |
| 8 | 8 | ||
| 9 | die() { | 9 | die() { |
| 10 | printf 'Fehler: %s\n' "$*" >&2 | 10 | printf 'Fehler: %s\n' "$*" >&2 |
| 11 | exit 1 | 11 | exit 1 |
| 12 | } | 12 | } |
| 13 | 13 | ||
| 14 | have() { | 14 | have() { |
| 15 | command -v "$1" >/dev/null 2>&1 | 15 | command -v "$1" >/dev/null 2>&1 |
| 16 | } | 16 | } |
| 17 | 17 | ||
| 18 | download() { | 18 | download() { |
| 19 | url="$1" | 19 | url="$1" |
| 20 | file=$(basename "$url") | 20 | file=$(basename "$url") |
| 21 | 21 | ||
| 22 | if [ -f "$file" ]; then | 22 | if [ -f "$file" ]; then |
| 23 | printf "✓ %-32s vorhanden\n" "$file" | 23 | printf "✓ %-32s vorhanden\n" "$file" |
| 24 | return | 24 | return |
| 25 | fi | 25 | fi |
| 26 | 26 | ||
| 27 | printf "→ Lade %s herunter\n" "$file" | 27 | printf "→ Lade %s herunter\n" "$file" |
| 28 | if have wget; then | 28 | if have wget; then |
| 29 | wget -q --show-progress "$url" | 29 | wget -q --show-progress "$url" |
| 30 | elif have curl; then | 30 | elif have curl; then |
| 31 | curl -fLO "$url" | 31 | curl -fLO "$url" |
| 32 | else | 32 | else |
| 33 | die "weder wget noch curl gefunden" | 33 | die "weder wget noch curl gefunden" |
| 34 | fi | 34 | fi |
| 35 | } | 35 | } |
| 36 | 36 | ||
| 37 | main() { | 37 | main() { |
| 38 | download "https://ftp.nluug.nl/pub/vim/runtime/spell/de.utf-8.spl" | 38 | download "https://ftp.nluug.nl/pub/vim/runtime/spell/de.utf-8.spl" |
| 39 | download "https://ftp.nluug.nl/pub/vim/runtime/spell/de.utf-8.sug" | 39 | download "https://ftp.nluug.nl/pub/vim/runtime/spell/de.utf-8.sug" |
| 40 | 40 | ||
| 41 | printf "\nWörterbücher für Neovim installiert!\n" | 41 | printf "\nWörterbücher für Neovim installiert!\n" |
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | main "$@" | 44 | main "$@" |
