prima-twig 0.2.12 → 0.2.14

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/bin/twig-deploy +6 -4
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 510aa2cae37bc86afd3b8f4ee8c19061cfabbdf9
4
- data.tar.gz: 5cb119298a3c479307ceb31b98b9a743a22d72e1
3
+ metadata.gz: a10a63db774a0ba868946173fda9b6e65ba93402
4
+ data.tar.gz: 4bb6c872e5b9342367cc05c745b79ece43bbc024
5
5
  SHA512:
6
- metadata.gz: c5a0e3bf3e65778693f82899981db63156de71523fdb3387102dc2f58d939a9ed0fcb954d3fdbd7cb8adcce933a1e2c0684933e18ef0369ba8655f348495155a
7
- data.tar.gz: 99029f1cb6a7170aec2c9ecfa5a7a594e45703a3054866e113a5d8ac9caa1bfe473ecf00f069d1880211564a1627d3e1bb9f46bdf688344125df6c01f2ce8222
6
+ metadata.gz: c7429b2ffd7656c4908255b1fa5e06dbf81ce8e01b7ad89e6b019d9e3603e2f363dff326cb0a064c85a828b8f8b1cd40575cd44ffd7ae2d6a437bfdc5f6e4cca
7
+ data.tar.gz: 49fb9e5381ad2485a8cbe5134d4510f6f5de821931d3820e63bd06d561804d4feeb68673bafb1e1dd0625c8ced5c19fed76374517a67eac14a0076bddcd94ec2
data/bin/twig-deploy CHANGED
@@ -15,7 +15,7 @@ def help_content
15
15
  twig-deploy
16
16
  ===========
17
17
 
18
- Updates master and push to origin
18
+ Deploys prima in production
19
19
 
20
20
  Synopsis
21
21
  --------
@@ -25,7 +25,7 @@ Synopsis
25
25
  Description
26
26
  -----------
27
27
 
28
- Merges dev in master and push dev and master to origin, than returns to the actual branch
28
+ It will ask you which artifact you want to deploy, run bin/deploy script and then send an email to the team when it's done.
29
29
 
30
30
  Subcommand for Twig: <http://rondevera.github.io/twig/>
31
31
  Author: Andrea Usuelli <https://github.com/andreausu>
@@ -70,17 +70,19 @@ class Review
70
70
  exec_step deploy_command if @prima.yesno "Sei sicuro di voler effettuare il deploy in produzione?".blue
71
71
 
72
72
  user = `git config user.name`
73
+ artifact = artifacts.select {|v| v[:rev] == artifact_rev}.first
73
74
 
74
75
  mail = Mail.new do
75
76
  from 'developers@prima.it'
76
77
  to 'developers@prima.it'
77
- subject "#{user} ha effettuato il deploy della release #{artifact}"
78
+ subject "#{user} ha effettuato il deploy della revision #{artifact[:rev]}"
78
79
  end
79
80
 
80
81
  body = "# Deploy in produzione avvenuto con successo!\n\n"
81
82
  body << "### Data: #{Time.now.strftime('%d/%m/%Y %H:%M:%S')}\n"
82
83
  body << "### Utente: #{user}\n"
83
- body << "### Release: [#{artifact}](https://github.com/primait/prima/releases/tag/#{ERB::Util.url_encode(artifact)})\n"
84
+ body << "### Revision: [#{artifact[:rev]}](https://github.com/primait/prima/commit/#{artifact[:rev]}) del #{artifact[:created_at].strftime('%d/%m/%Y %H:%M:%S')}\n"
85
+ body << "### Branch: [#{artifact[:branch]}](https://github.com/primait/prima/tree/#{artifact[:branch]})\n"
84
86
 
85
87
  htmlBody = Redcarpet::Markdown.new(Redcarpet::Render::HTML.new).render body
86
88
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prima-twig
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.12
4
+ version: 0.2.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matteo Giachino