diff --git a/.gitignore b/.gitignore index 1226837..96e91ce 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ /v2.4.1.tar.gz /cli-3.0.11.tar.gz +/cli-3.0.12.tar.gz diff --git a/0001-Disable-self-update.patch b/0001-Disable-self-update.patch index 6faf960..5e6878c 100644 --- a/0001-Disable-self-update.patch +++ b/0001-Disable-self-update.patch @@ -1,7 +1,7 @@ -From a0cb4fefa7f8e2866400f28efdf0577edca0e264 Mon Sep 17 00:00:00 2001 +From 3e4643e969640dc9de10b00c7f0639f9ee066491 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Sun, 10 Feb 2019 00:58:28 -0500 -Subject: [PATCH 1/2] Disable self-update. +Subject: [PATCH] Disable self-update. Signed-off-by: Elliott Sales de Andrade --- @@ -30,5 +30,5 @@ index 29f6d64..2e0ff74 100644 func (c *CLI) fetchLatestRelease() error { -- -2.20.1 +2.21.0 diff --git a/0002-Make-zsh-completion-work-on-fpath.patch b/0002-Make-zsh-completion-work-on-fpath.patch deleted file mode 100644 index 38eebc4..0000000 --- a/0002-Make-zsh-completion-work-on-fpath.patch +++ /dev/null @@ -1,61 +0,0 @@ -From 3aeee80e4c2eec810fdfe33c58d7285b73c0dc30 Mon Sep 17 00:00:00 2001 -From: Elliott Sales de Andrade -Date: Sun, 10 Feb 2019 03:28:56 -0500 -Subject: [PATCH 2/2] Make zsh completion work on $fpath. - -This allows the file to be placed, e.g., in a system-wide -`site-functions` directory and just work automatically. - -Signed-off-by: Elliott Sales de Andrade ---- - shell/README.md | 14 ++++++++------ - shell/exercism_completion.zsh | 4 +++- - 2 files changed, 11 insertions(+), 7 deletions(-) - -diff --git a/shell/README.md b/shell/README.md -index e8a258d..110b80f 100644 ---- a/shell/README.md -+++ b/shell/README.md -@@ -17,15 +17,17 @@ adding the following snippet: - - ### Zsh - -+Load up the completion by placing the `exercism_completion.zsh` somewhere on -+your `$fpath` as `_exercism`. For example: -+ - mkdir -p ~/.config/exercism -- mv ../shell/exercism_completion.zsh ~/.config/exercism/exercism_completion.zsh -+ mv ../shell/exercism_completion.zsh ~/.config/exercism/_exercism - --Load up the completion in your `.zshrc`, `.zsh_profile` or `.profile` by adding --the following snippet -+and then add the directory to your `$fpath` in your `.zshrc`, `.zsh_profile` or -+`.profile` before running `compinit`: - -- if [ -f ~/.config/exercism/exercism_completion.zsh ]; then -- source ~/.config/exercism/exercism_completion.zsh -- fi -+ export fpath=(~/.config/exercism $fpath) -+ autoload -U compinit && compinit - - - #### Oh my Zsh -diff --git a/shell/exercism_completion.zsh b/shell/exercism_completion.zsh -index f215530..2c13112 100644 ---- a/shell/exercism_completion.zsh -+++ b/shell/exercism_completion.zsh -@@ -1,3 +1,5 @@ -+#compdef exercism -+ - _exercism() { - local curcontext="$curcontext" state line - typeset -A opt_args -@@ -33,4 +35,4 @@ _exercism() { - esac - } - --compdef '_exercism' exercism -+_exercism "$@" --- -2.20.1 - diff --git a/exercism.spec b/exercism.spec index a9b24d0..c03824a 100644 --- a/exercism.spec +++ b/exercism.spec @@ -32,7 +32,7 @@ %global import_path %{provider_prefix} Name: %{project} -Version: 3.0.11 +Version: 3.0.12 Release: 1%{?dist} Summary: Exercism command-line interface License: MIT @@ -40,9 +40,7 @@ URL: https://%{provider_prefix} Source0: https://%{provider_prefix}/archive/v%{version}/%{repo}-%{version}.tar.gz # Remove the github.com/inconshreveable/go-update dependency -Patch1: 0001-Disable-self-update.patch -# https://github.com/exercism/cli/pull/806 -Patch2: 0002-Make-zsh-completion-work-on-fpath.patch +Patch0001: 0001-Disable-self-update.patch # e.g. el6 has ppc64 arch without gcc-go, so EA tag is required ExclusiveArch: %{?go_arches:%{go_arches}}%{!?go_arches:%{ix86} x86_64 aarch64 %{arm}} @@ -85,6 +83,8 @@ install -p out/exercism %{buildroot}%{_bindir}/ # shell completion install -d %{buildroot}%{_datadir}/bash-completion/completions install -Dpm0644 shell/exercism_completion.bash %{buildroot}%{_datadir}/bash-completion/completions/exercism +install -d %{buildroot}%{_datadir}/fish/completions +install -Dpm0644 shell/exercism.fish %{buildroot}%{_datadir}/fish/completions/exercism.fish install -d %{buildroot}%{_datadir}/zsh/site-functions install -Dpm0644 shell/exercism_completion.zsh %{buildroot}%{_datadir}/zsh/site-functions/_exercism @@ -120,11 +120,19 @@ mkdir -p $TMPDIR %dir %{_datadir}/bash-completion %dir %{_datadir}/bash-completion/completions %{_datadir}/bash-completion/completions/exercism +%dir %{_datadir}/fish +%dir %{_datadir}/fish/completions +%{_datadir}/fish/completions/exercism.fish +%dir %{_datadir}/zsh %dir %{_datadir}/zsh/site-functions %{_datadir}/zsh/site-functions/_exercism %changelog +* Wed Jul 10 2019 Elliott Sales de Andrade - 3.0.12-1 +- Update to latest version +- Add fish completions + * Sat Feb 09 2019 Elliott Sales de Andrade - 3.0.11-1 - Update to latest version diff --git a/sources b/sources index b6cf20a..e344a3a 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (cli-3.0.11.tar.gz) = 2179a012ee395e4fb43cb2712a61d89f386af41637430f3400cb0a1c787754c4d8c7b286d5d6f919835f21b591f45177b5bdc58e9d94f7dc8d00b6c632a06eb9 +SHA512 (cli-3.0.12.tar.gz) = 72494d67d4b62652915b47983fb8bf5b527394bfdcb58c935a55d3abb03904343367d95053379498d594ff4e2f962b9e1f6c50b7e20b136f800b8f98324d370e