vagrant-notify 0.5.5 → 0.5.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ce5183e2af2924f3e36012a0192cdc47e85cea86
4
- data.tar.gz: e0687251ff6fe0c3f5910c7653de6974f8bfbf66
3
+ metadata.gz: e815d8366c2310e48ee25a05e77ac87338c2dec8
4
+ data.tar.gz: 5879a33968786bfbc76c1879f94025450eb16acd
5
5
  SHA512:
6
- metadata.gz: f7fbaf96735f55579d4915037f2e202dac6b21fa0ba1ca7683884300c9c2930fbd05a1ea935ec46529aaa45f33b0cd60cd202bb8c3a1176b2e1beb4c754e053a
7
- data.tar.gz: 2c936be449932589cd77d4af61f8fdafe80e831f4754cd33a11aaea5335813db8ee30687d8325da51c37fd757d4d2997f8edb109badbf35590081d2935ec7f82
6
+ metadata.gz: 073a9a590caea2049c0fe203754a6cb68e3533665680920ccd7a99a7470c63d6c2718e0c426e3f4c15350eccb5feb8d47286d127391500ee2516aadbda21ead2
7
+ data.tar.gz: 7e5112adff7a124289b01f3eb8d7182bd75fde71a1173eb725be8572503a5075e1303e22179ee59763625a7ef1b301c3574e2f8a84df1b2c0def36ac223a785d
@@ -1,5 +1,4 @@
1
1
  language: ruby
2
2
  bundler_args: --without development
3
3
  rvm:
4
- - 2.0.0
5
- - 2.3.0
4
+ - 2.3.3
@@ -1,3 +1,8 @@
1
+ ## [0.5.6](https://github.com/fgrehm/vagrant-notify/compare/v0.5.5...v0.5.6) (September 29, 2017)
2
+ BUG FIXES
3
+
4
+ - `vagrant resume` bug fix. [[GH-39]](https://github.com/fgrehm/vagrant-notify/issues/39)
5
+
1
6
  ## [0.5.5](https://github.com/fgrehm/vagrant-notify/compare/v0.5.4...v0.5.5) (May 13, 2017)
2
7
  IMPROVEMENTS
3
8
 
@@ -11,16 +11,15 @@ growlnotify -t "Vagrant VM" -m "$*"
11
11
 
12
12
  ## OS X
13
13
 
14
- The `notify-send` script can forward the message to either
14
+ The easiest configuration is using the built-in [AppleScript](https://github.com/fgrehm/vagrant-notify/blob/master/examples/osx/applescript/notify-send.rb) support for notifications. Alternatively, you can also create a `notify-send` script that forwards messages to other third party notifications applications like
15
15
  [Growl](http://growl.info/) with [GrowlNotify](http://growl.info/downloads) (version 1.2.2 is free but unreliable)
16
16
  or to the [Notification Center](http://support.apple.com/kb/HT5362) available on OS X 10.8+
17
17
  using f.ex. [terminal-notifier](https://github.com/alloy/terminal-notifier).
18
18
 
19
-
19
+ * [AppleScript wrapper script](https://github.com/fgrehm/vagrant-notify/blob/master/examples/osx/applescript/notify-send.rb)
20
20
  * [terminal-notifier wrapper script](https://github.com/fgrehm/vagrant-notify/blob/master/examples/osx/terminal-notifier/notify-send.rb)
21
21
  * [growlnotify wrapper script](https://github.com/fgrehm/vagrant-notify/blob/master/examples/osx/growl_for_mac/notify-send.rb)
22
22
 
23
-
24
23
  ## Windows
25
24
 
26
25
  You can use the freeware application [notify-send for Windows](http://vaskovsky.net/notify-send/), make sure the notify-send binary is available on `Path`. Or you can create your own notify-send program and compile it to an .exe binary executable.
@@ -0,0 +1,34 @@
1
+ #!/usr/bin/env ruby
2
+ # -*- mode: ruby -*-
3
+ # vi: set ft=ruby :
4
+
5
+ # Example OS X (>= 10.9) applescript notify-send wrapper script.
6
+
7
+ require 'optparse'
8
+
9
+
10
+ options = {}
11
+ OptionParser.new do |opts|
12
+ opts.on('-u', '--urgency LEVEL') { |v| options[:u] = v } # Option gets removed
13
+ opts.on('-t', '--expire-time TIME') { |v| options[:t] = v } # Option gets removed
14
+ opts.on('-a', '--app-name APP_NAME') { |v| options[:a] = v } # TO DO: Set to -title
15
+ opts.on('-i', '--icon ICON[,ICON...]') { |v| options[:i] = v } # Option gets removed
16
+ opts.on('-c', '--category TYPE[,TYPE...]') { |v| options[:c] = v } # Option gets removed
17
+ opts.on('-h', '--hint TYPE:NAME:VALUE') { |v| options[:h] = v } # Option gets removed
18
+ opts.on('-v', '--version') { |v| options[:v] = v } # Option gets removed
19
+ end.parse!
20
+
21
+
22
+ if ARGV.length == 0
23
+ puts "No summary specified"
24
+ exit 1
25
+ elsif ARGV.length == 1
26
+ message = "\"#{ARGV[0]}\""
27
+ elsif ARGV.length == 2
28
+ message = "\"#{ARGV[0]}\" with title \"#{ARGV[1]}\""
29
+ else
30
+ puts "Invalid number of options."
31
+ exit 1
32
+ end
33
+
34
+ system "osascript -e 'display notification #{message} sound name \"default\"'"
@@ -11,6 +11,7 @@ module Vagrant
11
11
 
12
12
  start_server_hook = lambda do |hook|
13
13
  require_relative './action'
14
+ hook.before Vagrant::Action::Builtin::WaitForCommunicator, Vagrant::Action::Builtin::ConfigValidate
14
15
  hook.after Vagrant::Action::Builtin::WaitForCommunicator, Vagrant::Notify::Action.action_start_server
15
16
  end
16
17
 
@@ -1,5 +1,5 @@
1
1
  module Vagrant
2
2
  module Notify
3
- VERSION = "0.5.5"
3
+ VERSION = "0.5.6"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-notify
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.5
4
+ version: 0.5.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fabio Rehm
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2017-05-13 00:00:00.000000000 Z
12
+ date: 2017-09-30 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: A Vagrant plugin that forwards `notify-send` from guest to host machine
15
15
  and notifies provisioning status
@@ -32,6 +32,7 @@ files:
32
32
  - Rakefile
33
33
  - development/Vagrantfile
34
34
  - examples/README.md
35
+ - examples/osx/applescript/notify-send.rb
35
36
  - examples/osx/growl_for_mac/notify-send.rb
36
37
  - examples/osx/terminal-notifier/notify-send.rb
37
38
  - examples/windows/growl_for_windows/notify-send.rb