Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

clocker

Package Overview
Dependencies
Maintainers
1
Versions
80
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

clocker - npm Package Compare versions

Comparing version 1.2.0 to 1.3.0

18

bin/cmd.js

@@ -26,7 +26,8 @@ #!/usr/bin/env node

var d = argv.date ? new Date(argv.date) : new Date;
var type = argv.type || argv.t;
var message = argv.message;
var type = argv.type;
var pkey = strftime('time!%F %T', d);
var tkey = 'time-type!' + type + '!' + strftime('%F %T', d);
db.batch([
{ type: 'put', key: pkey, value: { type: type } },
{ type: 'put', key: pkey, value: { type: type, message: message } },
{ type: 'put', key: tkey, value: 0 }

@@ -52,3 +53,7 @@ ], error);

function onrow (row) {
if (argv.message) row.value.message = argv.message;
var m = argv.message;
if (m) {
if (row.value.message) m = row.value.message + '\n' + m;
row.value.message = m;
}
row.value.end = strftime('%F %T', d);

@@ -61,5 +66,6 @@ db.put(row.key, row.value, error);

var end = strftime('%F %T', new Date(argv._[2]));
var type = argv.type || argv.t;
var message = argv.message;
var type = argv.type;
var value = { type: type, end: end };
var value = { type: type, message: message, end: end };
var pkey = 'time!' + start;

@@ -90,3 +96,3 @@ var tkey = 'time-type!' + type + '!' + start;

else if (argv._[0] === 'data') {
var type = argv.type || argv.t || argv._[1];
var type = argv.type || argv._[1];
var rate = argv.rate || argv.r || argv._[2];

@@ -93,0 +99,0 @@ var title = argv.title || 'consulting';

usage:
clocker start {-t TYPE}
Start the clock. Optionally give a TYPE.
clocker start {-t TYPE, -m MESSAGE}
Start the clock. Optionally give a TYPE and MESSAGE.
clocker stop
clocker stop {-m MESSAGE}
Stop the clock.

@@ -21,3 +21,3 @@

clocker add START END {-t TYPE}
clocker add START END {-t TYPE, -m MESSAGE}
Add a hours from START to END as date strings.

@@ -24,0 +24,0 @@

{
"name": "clocker",
"version": "1.2.0",
"version": "1.3.0",
"description": "track project hours",

@@ -5,0 +5,0 @@ "bin": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc