hiiro 0.1.47 → 0.1.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/hiiro/version.rb +1 -1
- metadata +1 -10
- data/bin/g-pr +0 -327
- data/bin/h-dot +0 -35
- data/bin/h-dotfiles +0 -42
- data/bin/h-osubtask +0 -32
- data/bin/h-otask +0 -867
- data/bin/h-pr-monitor +0 -3
- data/bin/h-pr-watch +0 -3
- data/bin/h-runtask +0 -79
- data/bin/h-vim +0 -63
data/bin/h-pr-monitor
DELETED
data/bin/h-pr-watch
DELETED
data/bin/h-runtask
DELETED
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
|
|
3
|
-
stamp="$(date +"%Y%m%d%H%M%S")"
|
|
4
|
-
logfile="tmp/run-task.$stamp"
|
|
5
|
-
task_logfile="tmp/run-task.status.$stamp"
|
|
6
|
-
# task_name="generate-sso-config.retailers-domain.customers-backend.customers"
|
|
7
|
-
task_name="generate-sso-config.partners-domain.customers-backend.customers"
|
|
8
|
-
full_sha="$(git log -1 | head -1 | sed 's/commit //;s/[[:space:]].*//')"
|
|
9
|
-
sha="$(echo -n "$full_sha" | sed 's/\(.......\).*/\1/')"
|
|
10
|
-
trusted=${2:-false}
|
|
11
|
-
method_choice=${1:-id}
|
|
12
|
-
|
|
13
|
-
if test $method_choice = "id"
|
|
14
|
-
then
|
|
15
|
-
trusted=false
|
|
16
|
-
SSO_CONFIG="{\"retailer_name\":\"Joshtestidtoken\",\"method_choice\":\"id_token\",\"client_id\":\"updated client id\",\"popup\":true,\"trusted\":${trusted},\"scope\":\"default\",\"activation_status\":\"active\",\"store_config_id\":1459,\"code_challenge_method\":\"S256\",\"user_info_mapping\":{\"provider_uid\":\"sub\",\"first_name\":\"user_first_name\",\"last_name\":\"user_last_name\",\"email\":\"email\",\"phone\":\"default\",\"membership_number\":\"rewards_number\"},\"token_endpoint\":\"http://example.com/token\",\"authorization_endpoint\":\"http://example.com/authorization\",\"logout_endpoint\":\"http://example.com/logout\"}"
|
|
17
|
-
else
|
|
18
|
-
SSO_CONFIG="{\"retailer_name\":\"Joshuitest\",\"method_choice\":\"userinfo endpoint\",\"client_id\":\"updated client id\",\"popup\":true,\"trusted\":${trusted},\"scope\":\"default\",\"activation_status\":\"active\",\"store_config_id\":1459,\"code_challenge_method\":\"S256\",\"user_info_mapping\":{\"provider_uid\":\"sub\",\"first_name\":\"user_first_name\",\"last_name\":\"user_last_name\",\"email\":\"email\",\"phone\":\"default\",\"membership_number\":\"rewards_number\"},\"token_endpoint\":\"http://example.com/token\",\"authorization_endpoint\":\"http://example.com/authorization\",\"logout_endpoint\":\"http://example.com/logout\",\"user_info_endpoint\":\"http://example.com/user_info\"}"
|
|
19
|
-
fi
|
|
20
|
-
|
|
21
|
-
echo "stamp: $stamp"
|
|
22
|
-
echo "logfile: $logfile"
|
|
23
|
-
echo "task_name: $task_name"
|
|
24
|
-
echo "full_sha: $full_sha"
|
|
25
|
-
echo "sha: $sha"
|
|
26
|
-
echo "trusted: $trusted"
|
|
27
|
-
echo "method_choice: $method_choice"
|
|
28
|
-
echo "SSO_CONFIG: $SSO_CONFIG"
|
|
29
|
-
echo
|
|
30
|
-
echo "$SSO_CONFIG" | jq
|
|
31
|
-
|
|
32
|
-
mkdir -pv tmp
|
|
33
|
-
|
|
34
|
-
if test -f tmp/run-task
|
|
35
|
-
then
|
|
36
|
-
mv -v tmp/run-task "$logfile"
|
|
37
|
-
fi
|
|
38
|
-
|
|
39
|
-
if ! test -f $logfile
|
|
40
|
-
then
|
|
41
|
-
isc task -e production run $task_name $full_sha --command 'bundle exec rake partners_domain:sso_config:generate' --conf "SSO_CONFIG=${SSO_CONFIG}" | tee $logfile
|
|
42
|
-
fi
|
|
43
|
-
|
|
44
|
-
uuid="$(egrep -o '\b[0-9a-f-]{36}\b' $logfile | head -1)"
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
echo
|
|
48
|
-
echo "UUID: $uuid"
|
|
49
|
-
echo
|
|
50
|
-
|
|
51
|
-
while true
|
|
52
|
-
do
|
|
53
|
-
sleep 5
|
|
54
|
-
clear
|
|
55
|
-
isc -e production task runs "$task_name" "$uuid" | tee $task_logfile
|
|
56
|
-
echo
|
|
57
|
-
egrep 'Status: (pending|in-progress)' $task_logfile || break
|
|
58
|
-
done
|
|
59
|
-
|
|
60
|
-
log_url="$(egrep -o 'Datadog Logs:.*' $task_logfile | sed 's/Datadog Logs: //')"
|
|
61
|
-
|
|
62
|
-
if [[ ! -z $log_url ]]
|
|
63
|
-
then
|
|
64
|
-
open "$log_url"
|
|
65
|
-
fi
|
|
66
|
-
|
|
67
|
-
if egrep 'Status: failed' $task_logfile
|
|
68
|
-
then
|
|
69
|
-
say "task failed"
|
|
70
|
-
else
|
|
71
|
-
if egrep 'Status: succe' $task_logfile
|
|
72
|
-
then
|
|
73
|
-
say "task successful"
|
|
74
|
-
fi
|
|
75
|
-
fi
|
|
76
|
-
|
|
77
|
-
echo
|
|
78
|
-
rm -v $logfile $task_logfile
|
|
79
|
-
|
data/bin/h-vim
DELETED
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env ruby
|
|
2
|
-
|
|
3
|
-
require 'hiiro'
|
|
4
|
-
|
|
5
|
-
BASE_DIR = CONFIG_DIR = File.join(Dir.home, '.config/nvim')
|
|
6
|
-
TMUX_SESSION_NAME = 'vim'
|
|
7
|
-
|
|
8
|
-
o = Hiiro.init(*ARGV, plugins: [Tmux, Pins, Project])
|
|
9
|
-
|
|
10
|
-
o.add_subcmd(:edit) { |*args|
|
|
11
|
-
nvim = ENV['EDITOR']
|
|
12
|
-
system(nvim, __FILE__)
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
o.add_subcmd(:path) { |*args|
|
|
16
|
-
print BASE_DIR
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
o.add_subcmd(:init, :config) { |*args|
|
|
20
|
-
nvim = ENV['EDITOR']
|
|
21
|
-
|
|
22
|
-
Dir.chdir(BASE_DIR)
|
|
23
|
-
system(nvim, 'init.lua')
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
o.add_subcmd(:skf) { |*args|
|
|
27
|
-
Dir.chdir(BASE_DIR)
|
|
28
|
-
system('skf', *args)
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
o.add_subcmd(:rg) { |*args|
|
|
32
|
-
Dir.chdir(BASE_DIR)
|
|
33
|
-
system('rg', '-S', *args)
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
o.add_subcmd(:rgall) { |*args|
|
|
37
|
-
Dir.chdir(BASE_DIR)
|
|
38
|
-
system('rg', '-S', '--no-ignore-vcs', *args)
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
o.add_subcmd(:session) { |*args|
|
|
42
|
-
Dir.chdir(BASE_DIR)
|
|
43
|
-
|
|
44
|
-
o.switch_to_tmux_session(TMUX_SESSION_NAME)
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
# basically call :session
|
|
48
|
-
o.add_subcmd(:tmux) { |*args|
|
|
49
|
-
Dir.chdir(BASE_DIR)
|
|
50
|
-
|
|
51
|
-
o.switch_to_tmux_session(TMUX_SESSION_NAME)
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
if o.runnable?
|
|
55
|
-
o.run
|
|
56
|
-
else
|
|
57
|
-
puts format('ERROR: %s', :no_runnable_found)
|
|
58
|
-
|
|
59
|
-
puts
|
|
60
|
-
|
|
61
|
-
o.help
|
|
62
|
-
end
|
|
63
|
-
|