1
0
mirror of https://github.com/taigrr/wtf synced 2025-01-18 04:03:14 -08:00

70 Commits

Author SHA1 Message Date
Chris Cummer
fd794707cd
☢️ WTF-1031 Support multiple simultaneous configurations (#1032)
* WTF-1031 Rename WtfApp.app to WtfApp.tviewApp

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-1031 Add scaffolding for main to support multiple WtfApp instances

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-1031 WIP

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Remove common functionality from KeyboardWidget and into Base

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Augment with some descriptive comments

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Add full support for multiple app instances via the AppManager.

Still to do:

* Config support for multiple apps/multiple config files
* The ability to switch between apps

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Move SetTerminal out of main and into its own file

Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-12-21 03:25:41 -08:00
Chris Cummer
d6a0797bf2 Simplify the inclusion of the Common config settings into each module
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-11-26 23:18:46 -08:00
Chris Cummer
f9a06540f1 Simplify the view loading for the keyboard widget
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-11-26 23:12:15 -08:00
Chris Cummer
4a820dd0e5 Make every widget a keyboard widget
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-11-26 23:12:15 -08:00
Chris Cummer
3521ebf6e8 Rename SigilStr to PaginationMarker
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-11-26 23:07:30 -08:00
Chris Cummer
9f94e8c63a Add an app exit banner message 2020-10-11 16:55:16 -07:00
Chris Cummer
450483791f Obey the linter; make the linter happy
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-10-07 16:06:57 -07:00
Chris Cummer
87ce0d887e Pretty format the GitHub stats
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-10-06 20:05:19 -07:00
Matt Murphy
a0a85a5383 Make display whitespace consistent 2020-05-25 00:37:03 -04:00
Matt Murphy
b6a666fe59 Add setting to hide sections of GitHub module 2020-05-23 11:32:40 -04:00
Sam Roberts
3c405da087 Use docker-credential-helper to manage secrets
Store service credentials securely in the stores supported by docker:
- https://github.com/docker/docker-credential-helpers#available-programs

Introduces a top-level config property, "secretStore" and additional
command line arguments to manage the stored secrets.

The value of secretStore is used to find a helper command,
`docker-credential-<secretStore>`.

The docker project currently provides 4 store helpers:
- "osxkeychain" (OS X only)
- "secretservice" (Linux only)
- "wincred" (Windows only)
- "pass" (any OS supporting pass, which uses gpg2)

Docker-for-desktop installs the credential helpers above, as well as
"desktop" (docker-credential-desktop).

Generic installation instructions for the helpers:
- https://github.com/docker/docker-credential-helpers#installation

Users could provide additional helpers, the only requirement is that the
helper implements the credential store protocol:
- https://github.com/docker/docker-credential-helpers#development

The credential protocol is open, and new credential stores can be
implemented by any CLI satisfying the protocol:
- https://github.com/docker/docker-credential-helpers#development

The modifications to existing modules is not tested due to lack
of API keys, but demonstrates the unobtrusive changes required to
use the secret store.
2020-05-10 19:26:32 -07:00
Chris Cummer
f0ca3b8a58
Another actions test (#889)
* Another actions test

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Add BuildTest action

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Remove lint check for the time being (so many issues)

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Fix issues found by errcheck

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Fix errors found by staticcheck

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Fix issues found by goimports

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Comment out the  action for the time being

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Fix shadowed variables

Signed-off-by: Chris Cummer <chriscummer@me.com>

* go mod tidy

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Remove buildtest.yml

Signed-off-by: Chris Cummer <chriscummer@me.com>

* go mod tidy

Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-05-09 12:51:08 -07:00
Nikolay Mateev
4ec9d33a6f Add shortcuts for GitHub Pull Requests and Issues (#777) 2019-12-13 08:27:35 -08:00
Chris Cummer
200dbcc03c
WTF-730 Fix missing color key config error (#738)
* WTF-730 Fix missing color key config error

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-730 Add Subheading color formatting to modules

Users can now set a `subheading` color in their config to change the
color of subheadings in widget display.

Defaults to `red`.

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-730 Fix oustanding color issues

Clean up missing color config changes not addressed in earlier commits.

Signed-off-by: Chris Cummer <chriscummer@me.com>

* Remove unused dependency

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-730 Base cleanup

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-730 Fix a few bugs related to color config changes

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-730 Fix issues with PagerDuty subheading display

Signed-off-by: Chris Cummer <chriscummer@me.com>

* WTF-730 Fix bug with Todo list colour rendering

Signed-off-by: Chris Cummer <chriscummer@me.com>
2019-11-09 11:21:45 -08:00
Alex Fornuto
419d43670c remove pull request count from issue count (#694) 2019-10-12 17:51:53 -04:00
Chris Cummer
bf877f5fa7 Constantize the defaultFocus value for each module 2019-09-22 18:12:29 -07:00
Chris Cummer
f83e57c0b7 WTF-566 Support GitLab projects as list 2019-09-06 20:52:26 -07:00
Joel Valentine
9f7ff56f46 reducing the size of the cross 2019-09-06 12:20:36 +01:00
Joel Valentine
d4e0b0956f add unicode for exclamation mark 2019-09-06 02:50:53 +01:00
Joel Valentine
596bfbac02 fix: fixing linting for the github module
adding documentation to github module
fixing malformed icon causing display errors
2019-09-06 02:42:06 +01:00
Chris Cummer
faa2098912 Merge branch 'github-selection' of github.com:Midnight-Conqueror/wtf into Midnight-Conqueror-github-selection 2019-09-05 05:23:59 -07:00
Sean Smith
12a006f5a8 Pass through github client errors to display
Per #598, we crash on occasion.
We are swallowing errors incorrectly, and should catch/render
2019-09-04 21:26:28 -04:00
Joel Valentine
bd2f73aea5 unselecting correctly 2019-09-04 18:39:23 +01:00
Joel Valentine
c21b7c32a8 appending to a slice and referencing items within that using the currently selected 2019-09-04 17:55:32 +01:00
Joel Valentine
cbae7449b0 adding back padding 2019-08-31 19:24:24 +01:00
Joel Valentine
b98ce54750 scroll to top when unselecting 2019-08-31 19:01:29 +01:00
Joel Valentine
74d2fbe833 using the correct order and maintaining scroll position when changing source 2019-08-31 18:58:25 +01:00
Joel Valentine
5740b689be adding back mergedString 2019-08-31 17:27:49 +01:00
Joel Valentine
925930f76f addressing performance 2019-08-31 17:24:13 +01:00
Joel Valentine
10f020405f instead of resetting the selected each refresh now setting the max each refresh 2019-08-31 17:08:27 +01:00
Joel Valentine
70c5e02ca9 fixing an issue where after a refresh the maxItems would be greater than the actual amount 2019-08-31 16:39:33 +01:00
Joel Valentine
d212037ff5 cleaning up 2019-08-31 16:05:52 +01:00
Joel Valentine
d0308142a3 changing keybind 2019-08-31 15:47:28 +01:00
Joel Valentine
ccaca4f1c0 using just the pr/issue number as highlighted 2019-08-31 15:47:28 +01:00
Joel Valentine
55937c4c40 added highlighting and opening of pull requests 2019-08-31 15:47:28 +01:00
Chris Cummer
fce8b69459 Support case-insensitive 'apiKey' config keys
'apiKey' is one that people are likely to spell wrong in their configs
as 'apikey'. Given that there's no sanity-checking around required
config values yet, and a missing API key can cause silent failures in
some modules, be liberal in accepting spelling.
2019-08-29 06:34:52 -07:00
Sean Smith
14e7619075 Renormalize the redraw function
Have all instances take a function
Update the remaining modules to take this into account
Numerous smaller refactors to make some widgets work more or less the same
2019-08-27 21:51:37 -04:00
Sean Smith
51e4325f0b Handle all the widgets that use GetRect 2019-08-24 23:20:38 -04:00
Chris Cummer
523a0bec2c Remove the need for every module to define a widget.Refresh keyboard control 2019-08-23 21:18:51 -07:00
Chris Cummer
5337656c58 Remove the need for every module to define a widget.ShowHelp keyboard control
This common functionality is moved up to KeyboardWidget. Modules now
include widget.InitializeCommonControls() instead.
2019-08-23 21:18:51 -07:00
Chris Cummer
4e46fff145 Move the utils.go file into the /utils directory 2019-08-05 10:50:12 -07:00
Chris Cummer
dbc047516d Move all components responsible for module composition into /view 2019-08-04 21:42:40 -07:00
Chris Cummer
c17678013d Fix a couple of 'go vet' issues 2019-08-03 17:16:50 -07:00
Chris Cummer
b07f3c5e67 Reimpliments the module configuration validation
Now supports displaying errors from multiple widgets.
2019-07-07 16:04:43 -07:00
Sean Smith
5f57edb212 Even more help settings
Blitz through g
Clean up a setting that no longer exists for gcal
2019-07-04 11:40:53 -04:00
Chris Cummer
e846fdeef8 Update go-github dependencies 2019-06-28 16:32:24 -07:00
Sean DuBois
93d91c9313 Add new key 'customQueries' to github module
This key allows users to pass an arbitrary amount of queries
that contain custom filters. A simple query that shows all closed
PRs could be written like the following.

```
customQueries:
  closedPullRequests:
    title: "Closed Requests"
    perPage: 10
    filter:
      - "is:closed"
      - "is:pr"
```

Resolves #469
2019-06-06 16:30:16 -07:00
Sean Smith
02e0666697 Remove more app usages which are unnecessary 2019-05-24 22:22:56 -04:00
Kirill Motkov
f0771cd013 Some code improvements
* Some assignments simplified by using assignment operators
* Rewrite switch statement with only one case as if.
* Rewrite if-else chain as a switch statement.
* go fmt `modules/todoist/project.go` file.
2019-05-21 17:29:09 +03:00
Sean Smith
a2f5db7847 Harmonize keyboard controls
Make sure everyone has a refresh option
Have specific ordering:
 - Help
 - Refresh
 - Select next
 - Select prev
 - ...

Add unselect where applicable
2019-05-20 18:45:08 -04:00