takeltau 0.36.1 → 0.36.3

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 401a6ec84063daaad2d0b2ba91232b5d3f0322a2675ecc61eef9998d22867378
4
- data.tar.gz: c79e35f420922cd660ea5e80504f6cb909b4387aedefa7fffeb3db97c6d4c847
3
+ metadata.gz: b2465bad2b7f3f05a0989db146bcd4aeebccb1157c03ccd54a34e2dc6653ad46
4
+ data.tar.gz: 5a5a34f4ca5c59e66ef99e6814aea3c07f8f591f9511ee24484473462fe9083c
5
5
  SHA512:
6
- metadata.gz: ff29b7c25e3955263a0bd1d0fa74f1ee5e43af8759d1d6daf3680084659aaae8c9610976e73524eea1d875738b161b2abaa7e9a0bff1c478dc33ddf945cd6b1a
7
- data.tar.gz: 7e5fc47759b9488e4f18019cce0eaf2221864ba7a08b8ab70dc3279eaa2f975a64f7e93130f305256c4f8a868f8960fed27d96a1940b436098af3c151afb6623
6
+ metadata.gz: a2ce4ee0a6cbf779b3f0066f46e4ad4a9ec500b704661b9e93b3b27c230246a129552d9dedbafa1ee858bc9482ec13d03b499b915914593799fbd3616cd10f91
7
+ data.tar.gz: d1bc6aa9527413db818055b1f6aecc0654352a41fbca79d1c461329b71d2d5ea1d6d2427b0795b268da856c1eab217e3aefdef71b32f9129e68db5f8e708ff78
@@ -24,6 +24,7 @@ cmd_git_check_hg_get_git_branch: 'git symbolic-ref HEAD'
24
24
  cmd_git_check_workspace_git_repo: 'git -C %{dir} rev-parse'
25
25
  cmd_git_check_workspace_pwd: 'pwd'
26
26
  cmd_git_lib_git_add_all: 'git add --all'
27
+ cmd_git_lib_git_add_hg_dirs: 'git add \*/.hg/\*'
27
28
  cmd_git_lib_git_commit: 'git commit --message="%{message}"'
28
29
  cmd_git_lib_git_pull_origin: 'git pull origin %{main}'
29
30
  cmd_git_lib_git_push_origin: 'git push origin %{main}'
@@ -20,6 +20,18 @@ module GitLib
20
20
  _git_lib_git_push_origin_hg
21
21
  end
22
22
 
23
+ # Push git workspace.
24
+ def git_lib_push_hg_dirs
25
+ log.info 'Pushing git workspace'
26
+
27
+ message = '"Update .hg mercurial directories'
28
+
29
+ return false unless _git_lib_git_add_hg_dirs
30
+ return false unless _git_lib_git_commit message
31
+
32
+ _git_lib_git_push_origin_hg
33
+ end
34
+
23
35
  private
24
36
 
25
37
  # git add all.
@@ -34,6 +46,18 @@ module GitLib
34
46
  false
35
47
  end
36
48
 
49
+ # git add hg dirs.
50
+ def _git_lib_git_add_hg_dirs
51
+ log.debug 'Adding all .hg mercurial dirs to git'
52
+
53
+ cmd_git_add_hg_dirs = config.active['cmd_git_lib_git_add_hg_dirs']
54
+
55
+ return true if try cmd_git_add_hg_dirs
56
+
57
+ log.error 'Unable to add all .hg mercurial dirs to git'
58
+ false
59
+ end
60
+
37
61
  # git commit.
38
62
  def _git_lib_git_commit(message)
39
63
  log.debug "Committing to git with message \"#{message}\""
@@ -3,6 +3,7 @@
3
3
  # tau hg pull
4
4
  module HgPull
5
5
  # Backend method for hg pull.
6
+ # rubocop:disable Metrics/AbcSize
6
7
  # rubocop:disable Metrics/MethodLength
7
8
  def hg_pull
8
9
  log.debug 'Pull hg repos'
@@ -25,9 +26,14 @@ module HgPull
25
26
  end
26
27
 
27
28
  log.info _hg_pull_hg_pull_repos
28
- true
29
+
30
+ return true if git_lib_push_hg_dirs
31
+
32
+ log.error 'Unable to push .hg mercurial directories'
33
+ false
29
34
  end
30
35
  # rubocop:enable Metrics/MethodLength
36
+ # rubocop:enable Metrics/AbcSize
31
37
 
32
38
  private
33
39
 
data/lib/takeltau/version CHANGED
@@ -1 +1 @@
1
- 0.36.1
1
+ 0.36.3
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: takeltau
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.36.1
4
+ version: 0.36.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Takelwerk