rabbit-slide-nishidayuya-kunibikirb07-git-cococo 2018.03.31

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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: ee39c1317e34637fee4737f0e6bc964d60cc91a3709db623bd56abb875eadd1a
4
+ data.tar.gz: 0dc51f5e13956cb82caf0be4a68700f494c4150bb79ba1a2832267034f90a77b
5
+ SHA512:
6
+ metadata.gz: bf309576127f139dcc3a0ab0bb2ce2cc39ea58d6dcb458d41afe41784824947741103910b4b9e970df2bb10a0898df7ca4329788c989a892ce95a71f67b4ffb8
7
+ data.tar.gz: a43c375686e1015fafec6e4d784f00b23bdc6feafea5fa9b6ff7145a8b408f6a6eda778b516816484a254892b9ca1275dd148b22a13a4e22de30ff55ca186ccd
data/.rabbit ADDED
@@ -0,0 +1 @@
1
+ git-cococo.md
data/README.md ADDED
@@ -0,0 +1,24 @@
1
+ # git cococoとRailsアプリ開発
2
+
3
+ git cococoの説明とRailsアプリケーション開発で使われる場面を説明します.
4
+
5
+ ## 作者向け
6
+
7
+ ### 表示
8
+
9
+ rake
10
+
11
+ ### 公開
12
+
13
+ rake publish
14
+
15
+ ## 閲覧者向け
16
+
17
+ ### インストール
18
+
19
+ gem install rabbit-slide-nishidayuya-kunibikirb07-git-cococo
20
+
21
+ ### 表示
22
+
23
+ rabbit rabbit-slide-nishidayuya-kunibikirb07-git-cococo.gem
24
+
data/Rakefile ADDED
@@ -0,0 +1,17 @@
1
+ require "rabbit/task/slide"
2
+
3
+ # Edit ./config.yaml to customize meta data
4
+
5
+ spec = nil
6
+ Rabbit::Task::Slide.new do |task|
7
+ spec = task.spec
8
+ # spec.files += Dir.glob("doc/**/*.*")
9
+ # spec.files -= Dir.glob("private/**/*.*")
10
+ # spec.add_runtime_dependency("YOUR THEME")
11
+ end
12
+
13
+ desc "Tag #{spec.version}"
14
+ task :tag do
15
+ sh("git", "tag", "-a", spec.version.to_s, "-m", "Publish #{spec.version}")
16
+ sh("git", "push", "--tags")
17
+ end
data/config.yaml ADDED
@@ -0,0 +1,19 @@
1
+ ---
2
+ id: kunibikirb07-git-cococo
3
+ base_name: git-cococo
4
+ tags: []
5
+ presentation_date: '2018-03-31'
6
+ version: 2018.03.31
7
+ licenses: []
8
+ slideshare_id:
9
+ speaker_deck_id:
10
+ ustream_id:
11
+ vimeo_id:
12
+ youtube_id:
13
+ author:
14
+ markup_language: :markdown
15
+ name: Yuya.Nishida.
16
+ email:
17
+ rubygems_user: nishidayuya
18
+ slideshare_user: nishidayuya
19
+ speaker_deck_user: nishidayuya
data/git-cococo.md ADDED
@@ -0,0 +1,153 @@
1
+ # git cococoとRailsアプリ開発
2
+
3
+ author
4
+ : 西田雄也
5
+
6
+ date
7
+ : 2018-03-31 kunibiki.rb#7
8
+
9
+ allotted-time
10
+ : 30m
11
+
12
+ theme
13
+ : lightning-simple
14
+
15
+ # 自己紹介
16
+
17
+ * 西田雄也
18
+ * Twitter,GitHub: `@nishidayuya`
19
+ * 趣味:
20
+ * 小さいものを書く
21
+ * スノーボード
22
+ * なんとかGo(昨年末にTL40)
23
+
24
+ # git cococoってなに?
25
+
26
+ # git cococoってなに?
27
+
28
+ 実行したコマンドとともにコマンドによる変更をコミットするコマンド
29
+
30
+ ```
31
+ $ git cococo bundle update
32
+ ```
33
+
34
+ 0. コマンド実行前にコミット漏れがないか確認
35
+ 0. コマンド実行
36
+ 0. 変更点をコミット
37
+ * もう一度同じことをするコミットメッセージとともに
38
+
39
+ # git cococoってなに?
40
+
41
+ 実行したコマンドとともにコマンドによる変更をコミットするコマンド
42
+
43
+ ```
44
+ $ git cococo bundle update
45
+ ```
46
+
47
+ 0. コマンド実行前にコミット漏れがないか確認
48
+ 0. sedを実行
49
+ 0. 「run: git cococo bundle update」といったコミットメッセージで変更点をコミット
50
+
51
+ # もう一度同じことをするためのコミットメッセージ
52
+
53
+ * コマンド実行はいいとしてコミットメッセージを書くときにコピー&ペーストするの面倒.
54
+ * 毎回「どんな風に書いてたっけ...」って思いながらgit logで調べて同じように書くの面倒.
55
+
56
+
57
+
58
+ これを解決!
59
+
60
+ * 実行時に一回だけ書けば良い
61
+ * コミットメッセージはコマンド任せ
62
+
63
+ # 動機
64
+
65
+ 松江Ruby会議06のa_matsudaさんの話
66
+
67
+ * 「コード生成するコマンドを実行した場合は、そのままコミットするのが望ましい。」
68
+ * 読みたいのは人間が書いた部分
69
+ * コマンドでコード生成した部分は実行したコマンドがわかればいい
70
+
71
+ # デモ
72
+
73
+ # デモ: Railsアプリケーション開発でよくある使い方
74
+
75
+ # 構成
76
+
77
+ * git cococoはBourneシェルのシェルスクリプト
78
+ * 当初はRubyで実装していた.
79
+ * Windowsで動かしたくなった.
80
+ * mruby-cliもあるけど...
81
+ * Gitが動く環境にはBourneシェルあるいは互換のシェルがある.
82
+ * 自動試験はRubyで書いている.
83
+ * 単体テストとインテグレーションテスト
84
+ * test-unitが試験を書きやすい.
85
+
86
+ # 設計思想
87
+
88
+ # 設計思想: インストールが簡単
89
+
90
+ * 1ファイルのシェルスクリプトで実装してある.
91
+ * ダウンロードして実行パーミッションを与えるだけ.
92
+
93
+ ```
94
+ $ wget https://raw.githubusercontent.com/nishidayuya/git-cococo/master/exe/git-cococo
95
+ $ chmod a+x git-cococo
96
+ $ mv git-cococo move-to-PATH-env-directory/
97
+ ```
98
+
99
+ # 設計思想: 動く環境はGit
100
+
101
+ * Gitが動作する全ての環境で動く(はず).
102
+ * はず... 全ての環境で試験できません!
103
+ * 次の環境でCIをまわしている.
104
+ * Ubuntu
105
+ * Windows
106
+ * MacOSX
107
+ * 動かないUnixあるいはUnix互換OSがあれば教えてください&プルリクエスト歓迎です.
108
+
109
+ # 設計思想: 余計なことはしない
110
+
111
+ * 当初はコミット漏れがあれば自動的にgit stashすることを考えていた.
112
+
113
+
114
+
115
+ * 使ってみたところコマンド実行に失敗したときにstashしたままになるが,自動的にやっちゃうとstashしたものが消えたように見える.
116
+ * 焦っているときは特に困る.
117
+
118
+
119
+
120
+ * `--autostash`オプションで明示的に指示する形とした.
121
+
122
+ # 設計思想: Gitと合わせる(1)
123
+
124
+ `--autostash`オプションについて
125
+
126
+ * 当初は`--auto-stash`というオプション名で考えていた.
127
+
128
+
129
+
130
+ * git rebaseに`--autostash`オプションがあることに気がついて揃えた.
131
+
132
+ # 設計思想: Gitと合わせる(2)
133
+
134
+ git cococoという名前について
135
+
136
+ * Gitにはgit rerereコマンドがある.
137
+ * REuse REcorded REsolutionの略
138
+
139
+
140
+
141
+ * git cococo
142
+ * COmmit COmpletely COmmand outputの略
143
+ * 意味が合っている.
144
+ * 短い.
145
+
146
+ # ご静聴ありがとうございました
147
+
148
+ インストールは
149
+ https://github.com/nishidayuya/git-cococo
150
+ より
151
+
152
+ 気に入ってくださったらスターとかいただけると
153
+ ~~調子に乗ります~~ 励みになります.
metadata ADDED
@@ -0,0 +1,63 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: rabbit-slide-nishidayuya-kunibikirb07-git-cococo
3
+ version: !ruby/object:Gem::Version
4
+ version: 2018.03.31
5
+ platform: ruby
6
+ authors:
7
+ - Yuya.Nishida.
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2018-03-31 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: rabbit
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 2.0.2
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: 2.0.2
27
+ description: git cococoの説明とRailsアプリケーション開発で使われる場面を説明します.
28
+ email:
29
+ -
30
+ executables: []
31
+ extensions: []
32
+ extra_rdoc_files: []
33
+ files:
34
+ - ".rabbit"
35
+ - README.md
36
+ - Rakefile
37
+ - config.yaml
38
+ - git-cococo.md
39
+ - pdf/kunibikirb07-git-cococo-git-cococo.pdf
40
+ homepage: http://slide.rabbit-shocker.org/authors/nishidayuya/kunibikirb07-git-cococo/
41
+ licenses: []
42
+ metadata: {}
43
+ post_install_message:
44
+ rdoc_options: []
45
+ require_paths:
46
+ - lib
47
+ required_ruby_version: !ruby/object:Gem::Requirement
48
+ requirements:
49
+ - - ">="
50
+ - !ruby/object:Gem::Version
51
+ version: '0'
52
+ required_rubygems_version: !ruby/object:Gem::Requirement
53
+ requirements:
54
+ - - ">="
55
+ - !ruby/object:Gem::Version
56
+ version: '0'
57
+ requirements: []
58
+ rubyforge_project:
59
+ rubygems_version: 2.7.3
60
+ signing_key:
61
+ specification_version: 4
62
+ summary: git cococoとRailsアプリ開発
63
+ test_files: []