npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

toggl-tuesday

v0.0.2

Published

Easily update your [Toggl](https://www.goggle.com) timesheet from the commandline. Unlike other tools, such as [toggl-cli](https://github.com/drobertadams/toggl-cli), this is a wizard that allows one to bulk update over several dates. Toggl-tuesday will c

Downloads

3

Readme

toggl-tuesday

Easily update your Toggl timesheet from the commandline. Unlike other tools, such as toggl-cli, this is a wizard that allows one to bulk update over several dates. Toggl-tuesday will create two 4-hours shifts for a specified date range. Weekends are skipped by default.

Pre-Requesites

Before getting this to run, you'll first need to download and install node and npm. Checkout nodejs.org for more details.

Installation

To uninstall using npm, simply run the following command.

npm install --global toggl-tuesday

Usage

To use toggl-tuesday, simply type toggl-tuesday along with an api key that you can get from https://toggl.com/app/profile

toggl-tuesday --apiKey <api key>

OR

toggl-tuesday -a <api key>

Although not recommended, you can also use your toggl username and password.

toggl-tuesday --username <user name> --password <password>

Getting help

View the help by typing

toggl-tuesday --help

OR

toggl-tuesday --h

Questions

Once started, the wizard will ask you a number of questions. Press Enter without typing to accept the default value. You can force the wizard to skip a question by specifying the answer using a command line flag.

Work Id

Frankly, I'm not sure what this represents, the API needs this value to function properly. I've found the best way to get this value is to use the --records flag to give you a list of previously entered records.

toggl-tuesday -a <api key> --records

OR

toggl-tuesday -a <api key> -r

Note: Skip by setting the --wid or -w flag.

Process Id

This identifies the project upon which you're working. As with the Work Id, this is most easily obtained by looking at previous records using the --records flag.

Note: Skip by setting the --pid or -p flag.

Timezone

This is the timezone offset. The application should deduce this automatically.

Note: Skip by setting the --timezone or -z flag. Be sure that the date is in the proper format: an integer from -12 to +12

What date will you begin?

This is the beginning date for your records it currently defaults to the current day. Be sure that the date is in the proper format: YYYY-MM-DD

Note: Skip by setting the --begin or -b flag.

What date will you end?

This is the end date for your records it currently defaults to two days from the current day (not from the specified begin date, but today's date). Be sure that the date is in the proper format: YYYY-MM-DD

Note: Skip by setting the --end or -e flag.

Additional Note: I had initially wanted this to default to two weeks, but toggl currently "has issues" displaying times in the future. I'm fairly confident that this works properly, but I'll wait until a future release to bump the timeframe. Until then, you may specify the date directly if you want this to go a full two weeks.

First shift start?

This is the beginning of your first 4 hour shift. It defaults to 6 (6am). Be sure that the date is in the proper format: an integer from 0 to 24

Note: Skip by setting the --first or -f flag.

Last shift start?

This is the beginning of your last 4 hour shift. It defaults to 12 (12pm). Be sure that the date is in the proper format: an integer from 0 to 24

Note: Skip by setting the --last or -l flag.

Example Pre-Answer

Ideally, you would run toggle-tuesday with a few pre-defined flags. Here's an example of how to do this.

Lets say that:

  • I have a work id of 10000
  • I have a process id of 99999
  • I live on the east coast of the US (GMT -4)
  • I plan to enter time starting on the 1st of April in 2017 (2017-04-01)
  • I plan on ending on the 30th of April in 2017 (2017-04-30)
  • I plan on working my first four-hour shift starting at 7am (7 hours)
  • I plan on working my second four-hour shift starting at 1pm (13 hours)

I can use the following command to skip all of the questions in the wizard (note: the -y flag)

toggl-tuesday -a <api token> -w 10000 -p 99999 -z -4 -b 2017-04-01 -e 2017-04-30 -s 6 -e 13 -y

Of course, I don't have to -- and probably shouldn't -- specify everything. If anything is skipped, the wizard will ask you for it. This will be useful for running the same command, but on multiple days.

toggl-tuesday -a <api token> -w 10000 -p 99999 -z -4 -b
What date will you begin? (2017-04-10)

Other flags

Test (--test, -t)

You can use the test flag to preview changes without making them. If you provide the test flag, you won't need to provide authentication credentials.

Weekends (--weekend, -k)

You can use the weekend flag to ensure that WEEKENDS ARE NOT SKIPPED.

Verbose (--verbose, -v)

You can use the verbose flag to get a bit more information out of the console.

Silent (--silent, -s)

You can use the silent flag to suppress all output from the console. WARNING: ALL OUTPUT WILL BE SUPPRESSED

Yes (--yes, -y)

Automatically answer "yes" to "Make these updates? (Y/n)" question.