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

451 Commits

Author SHA1 Message Date
Chris Cummer
4064d42fed Fix go.mod conflict
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-10-08 12:29:32 -07:00
Sean Smith
7643109c63 Fix unlocking bug noticed during refactor 2020-10-08 08:17:52 -04:00
Todd Trimble
2f70693656
Correct minor typo in clock settings help text (#993) 2020-10-07 22:11:39 -07:00
Sean Smith
e23cec2897 Let pty be optional 2020-10-07 19:40:26 -04:00
Sean Smith
34154620f6 Handle error handling better
Don't panic
Add function due to reuse
Catch all errors to appease CI
2020-10-07 19:40:26 -04:00
Sean Smith
57bf5c7417 Have cmdrunner use a tty
This lets us get proper coloring
Fixes #577
2020-10-07 19:40:26 -04: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
Sean Smith
3c63eee8d3
Create generalized todo module (#982)
* Create generalized todo module

Makes existing modules "backends"
This gives us a consistent interface

* Fix check issues

* Fix lint errors

* Make changes to stay on wtfutil todoist fork
2020-10-07 14:58:24 -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
Chris Cummer
f7d99c5eff Don't trim whitespace from beginning of widget
Some widgets format the output using whitespace padding
at the beginning.

Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-10-06 20:00:50 -07:00
Sean Smith
fcc2a211df Add natural ordering for clocks
This turns locations into an ordered array, so we can have a 'natural' ordering
This is backwards compatible
Resolves #896
2020-10-03 13:10:50 -04:00
Ying Fan Chong
9a366ffeb9 Fix sorting for feed without published date 2020-10-02 20:35:20 +08:00
Ying Fan Chong
bdf642b773 Fix help text 2020-10-01 22:24:33 +08:00
Ying Fan Chong
184b3744c2 Apply gofmt 2020-10-01 22:16:19 +08:00
Ying Fan Chong
c4ca3d9b2a Add capability to switch content between title, link and title+content 2020-10-01 22:12:31 +08:00
Chris Cummer
5e44a01699 Sort exchange rates alphabetically and group same base rates by row color
Before this, exchange rates were read from a map, which meant the
display order was random.

This ensures that the list of exchange rates displays in a consistent
order and visually denotes rates for the same currency.

Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-09-29 10:06:46 -07:00
Tim Hwang
9b0f4a50e8 fix: fix Jira module title formatting
Closes #942. Filing to get the ball rolling, happy to change anything.
2020-07-29 10:32:34 -04:00
Chris Cummer
fa5b35b27b WTF-897 Wrap exchange rate error messages for easier viewing
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-07-27 17:22:14 -07:00
Chris Cummer
fd91a48f58 WTF-897 Exchange Rate improvements
Allows the user to set the precision for their exchange rate values.

Config setting:
```
exchangerates:
  precision: 3
```

Default is `7`.

Also aligns converted values along the decimal place for improved
aesthetics.

Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-07-27 17:21:36 -07:00
Chris Cummer
a0e34507db Fix merge conflict
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-07-27 17:17:17 -07:00
A. Nackov
f051bdb239 Close #876 - fix todo modal editing feeling slow
Fixes #876. The modal shown when editing todos was feeling slow to start
It required an additional hit of `Enter` to show the modal.

This commit fixes it by queueing a `Draw` update - so now the modal
feels fast to show.

Tests:
* ran `make test`
* tested locally with a todo list
2020-07-24 08:20:29 +03:00
Chris Cummer
e581646d31 Include the link in incidents, and set the colours according to user config
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-07-23 09:50:01 -07:00
Chris Cummer
391ce432a7 go mod tidy
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-07-23 06:49:52 -07:00
Chris Cummer
24ba1ee07c Provides the option to display the date the current onCall schedule will
end.

Config setting:

```
  pagerduty:
    showOnCallEnd: [true|false]
```

If `true`, the date will be displayed below the onCall person's name:

```
eng-droplet
1 - Chris Cummer
    Jul 27, 2020
```

Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-07-23 06:23:26 -07:00
Chris Cummer
f104859679 Merge branch 'victorops_npe' of github.com:ripienaar/wtf into ripienaar-victorops_npe 2020-07-01 07:39:33 -07:00
R.I.Pienaar
15df0ee2f4
avoid npe on victorops settings
Signed-off-by: R.I.Pienaar <rip@devco.net>
2020-06-25 22:07:43 +02:00
Jon Hadfield
3dbfc14056
remove spurious formatting. 2020-06-22 18:56:53 +01:00
Jon Hadfield
0b63a56e40
enable user to disable emoji for weather module. 2020-06-22 18:47:28 +01:00
Matt
02ef02538d
Update widget.go 2020-06-07 18:11:17 -04:00
Matt Murphy
d3834271e0 Always show incidents if configured 2020-06-07 17:56:13 -04:00
Matt Murphy
aa5e5e70a9 Add TeamIDs and UserIDs filters for incidents 2020-06-07 16:58:44 -04:00
Chris Cummer
35505394d1 Merge branch 'pihole_5_api_compat' of github.com:jonhadfield/wtf into jonhadfield-pihole_5_api_compat 2020-05-30 13:02:11 -07:00
Jon Hadfield
988a9deee5
make PiHole module compatible with both versions 4 and 5 of PiHole. 2020-05-28 22:12:57 +01:00
Chris Cummer
92285b194f Merge branch 'master' of github.com:mryanmurphy/wtf into mryanmurphy-master 2020-05-26 21:25:11 -07:00
Matt Murphy
a0a85a5383 Make display whitespace consistent 2020-05-25 00:37:03 -04:00
Chris Cummer
b6f2d1423e Merge branch 'fix-gitlabtodo-domain' of github.com:gerchardon/wtf into gerchardon-fix-gitlabtodo-domain 2020-05-23 12:38:22 -07:00
Matt Murphy
b6a666fe59 Add setting to hide sections of GitHub module 2020-05-23 11:32:40 -04:00
Gerome Chardon
4a7bdeab3c Fix gitlabtodo usage of domain
Use domain in gitlabtodo
Handle error in gitlabtodo
2020-05-18 10:59:12 +02:00
Sam Roberts
4bb725db9e golangci-lint configuration file
golangci-lint can run all the currently enabled linters, and as far as I
can tell, does it in under 5 seconds as opposed to over 180 seconds
(compare `time make cilint` and `time make lint`).

Some of the linters that are listed in the "enabled" section but
commented out looked like a good idea to me, and fairly low hanging
fruit to fix, but they are not passing at the moment.

All the linters covered in the current Makefile are run.

TODO:
- replace lint target in Makefile with golangci-lint
- remove .github/workflow/errcheck.yml
2020-05-16 12:34:57 -07:00
Chris Cummer
e43c37cc07 Fix broken gCal title
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-05-15 01:39:11 -07: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
Chris Cummer
9cd9a58759 Fix a bunch of minor issues found by running staticcheck
Signed-off-by: Chris Cummer <chriscummer@me.com>
2020-05-06 22:44:24 -07:00
Adriano
e035f3a15a
Add ipv6 support to ipinfo (#885) 2020-05-02 07:05:49 -07:00
Risto Saarelma
c6f6036f5a
Fix feed module item sorting (#886)
Thanks!
2020-05-02 06:59:22 -07:00
Chris Cummer
880168989c Merge branch 'feature/gitlab-with-browser' of github.com:mogensen/wtf into mogensen-feature/gitlab-with-browser 2020-04-28 20:52:07 -07:00
Jon Hadfield
0b3a326fe3
fix digitalclock display bug. (#883) 2020-04-28 20:46:37 -07:00
Frederik Mogensen
dbab6be1d4 Gitlab: allow for opening items in browser 2020-04-27 09:08:37 +02:00
Chris Cummer
daf1e61335 Merge branch 'add_pihole' of github.com:jonhadfield/wtf into jonhadfield-add_pihole 2020-04-23 05:38:10 -07:00
Adriano
216124437a
Add event end time to gcal module display (#877)
* Add event end time to gcal module display

* Add settings for showing end time and add test coverage

* go mod tidy
2020-04-23 05:32:59 -07:00