Skip to content

Commit

Permalink
Bump version numbers in source
Browse files Browse the repository at this point in the history
  • Loading branch information
deanishe committed Dec 8, 2018
1 parent 5bf4b72 commit db298b4
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 19 deletions.
33 changes: 24 additions & 9 deletions README.md
Expand Up @@ -82,7 +82,6 @@ argv):
./program "$1"
```


Documentation
-------------

Expand All @@ -93,16 +92,32 @@ show how to use AwGo. Use one as a template to get your own workflow up and
running quickly.


Running/testing
---------------
Requirements
------------

The library (and therefore the unit tests) rely on being run in a minimally
Alfred-like environment, as they pull configuration options from the environment
variables set by Alfred.

This means that if you want to run AwGo-based code outside Alfred, e.g. in your
shell, you must set at least the following environment variables to meaningful
values, or the library will panic:

- `alfred_workflow_bundleid`
- `alfred_workflow_cache`
- `alfred_workflow_data`

And if you're using the update API, also:

- `alfred_workflow_version`


The library, and therefore the unit tests, rely on being run in an Alfred-like
environment, as they pull configuration options from environment variables
(which are set by Alfred).
Development
-----------

As such, you must `source` the `env.sh` script in the project root or run unit
tests via the `run-tests.sh` script (which also sets up an appropriate
environment before calling `go test`).
To create a sufficiently Alfred-like environment, you can `source` the `env.sh`
script in the project root or run unit tests via the `run-tests.sh` script
(which also sets up an appropriate environment before calling `go test`).


Licensing & thanks
Expand Down
2 changes: 1 addition & 1 deletion doc.go
Expand Up @@ -45,7 +45,7 @@ of AwGo and useful workflow idioms.
Features
As of AwGo 0.14, all applicable features of Alfred 3.6 are supported.
As of AwGo 0.15, all applicable features of Alfred 3.7 are supported.
The main features are:
Expand Down
4 changes: 2 additions & 2 deletions env.sh
Expand Up @@ -7,7 +7,7 @@ export alfred_workflow_cache="$HOME/Library/Caches/com.runningwithcrayons.Alfred
export alfred_workflow_data="$HOME/Library/Application Support/Alfred 3/Workflow Data/net.deanishe.awgo"

# Expected by ExampleNew
export alfred_workflow_version="0.14"
export alfred_workflow_version="0.15"
export alfred_workflow_name="AwGo"

# export alfred_debug="1"
Expand All @@ -19,4 +19,4 @@ export alfred_workflow_name="AwGo"
# export alfred_theme_subtext="0"
# export alfred_version="3.6"
# export alfred_version_build="901"
# export alfred_workflow_uid="user.workflow.4B0E9731-E139-4179-BC50-D7FFF82B269A"
# export alfred_workflow_uid="user.workflow.4B0E9731-E139-4179-BC50-D7FFF82B269A"
6 changes: 3 additions & 3 deletions run-tests.sh
Expand Up @@ -109,15 +109,15 @@ export alfred_workflow_cache="${testdir}/cache"
export alfred_workflow_data="${testdir}/data"

# Expected by ExampleNew
export alfred_workflow_version="0.14"
export alfred_workflow_version="0.15"
export alfred_workflow_name="AwGo"

cd "$root"

[[ $#@ -eq 0 ]] && {
pkgs=./...
pkgs=(go list ./...)
} || {
pkgs="$@"
pkgs=($@)
}

go test $gopts $pkgs
Expand Down
4 changes: 2 additions & 2 deletions testutils_test.go
Expand Up @@ -12,7 +12,7 @@ import (
)

var (
tVersion = "0.14"
tVersion = "0.15"
tName = "AwGo"
tBundleID = "net.deanishe.awgo"
tUID = "user.workflow.4B0E9731-E139-4179-BC50-D7FFF82B269A"
Expand Down Expand Up @@ -69,7 +69,7 @@ var (
<key>webaddress</key>
<string>https://github.com/deanishe/awgo</string>
<key>version</key>
<string>0.14</string>
<string>0.15</string>
<key>variables</key>
<dict>
<key>exported_var</key>
Expand Down
2 changes: 1 addition & 1 deletion workflow.go
Expand Up @@ -18,7 +18,7 @@ import (
)

// AwGoVersion is the semantic version number of this library.
const AwGoVersion = "0.14.0"
const AwGoVersion = "0.15.0"

// Default Workflow settings. Can be changed with the corresponding Options.
//
Expand Down
2 changes: 1 addition & 1 deletion workflow_test.go
Expand Up @@ -154,7 +154,7 @@ func ExampleNew() {
// Output:
// AwGo
// net.deanishe.awgo
// 0.14
// 0.15
}

// Pass one or more Options to New() to configure the created Workflow.
Expand Down

0 comments on commit db298b4

Please sign in to comment.