vagrant-notify 0.5.5 → 0.5.6
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/.travis.yml +1 -2
- data/CHANGELOG.md +5 -0
- data/examples/README.md +2 -3
- data/examples/osx/applescript/notify-send.rb +34 -0
- data/lib/vagrant-notify/plugin.rb +1 -0
- data/lib/vagrant-notify/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e815d8366c2310e48ee25a05e77ac87338c2dec8
|
4
|
+
data.tar.gz: 5879a33968786bfbc76c1879f94025450eb16acd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 073a9a590caea2049c0fe203754a6cb68e3533665680920ccd7a99a7470c63d6c2718e0c426e3f4c15350eccb5feb8d47286d127391500ee2516aadbda21ead2
|
7
|
+
data.tar.gz: 7e5112adff7a124289b01f3eb8d7182bd75fde71a1173eb725be8572503a5075e1303e22179ee59763625a7ef1b301c3574e2f8a84df1b2c0def36ac223a785d
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -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
|
|
data/examples/README.md
CHANGED
@@ -11,16 +11,15 @@ growlnotify -t "Vagrant VM" -m "$*"
|
|
11
11
|
|
12
12
|
## OS X
|
13
13
|
|
14
|
-
The `notify-send` script
|
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
|
|
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.
|
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-
|
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
|