All Projects → alexherbo2 → chronic

alexherbo2 / chronic

Licence: Unlicense license
A natural language date-time parser for the command-line

Programming Languages

crystal
512 projects
Makefile
30231 projects

Projects that are alternatives of or similar to chronic

core
The XP Framework is an all-purpose, object oriented PHP framework.
Stars: ✭ 13 (+0%)
Mutual labels:  date-time
Date4j
Code for date4j.net's simple date API, with a POM file, for upload to Maven Central.
Stars: ✭ 12 (-7.69%)
Mutual labels:  date-time
Time
Building a better date/time library for Swift
Stars: ✭ 1,983 (+15153.85%)
Mutual labels:  date-time
Calendarview
An Easy to Use Calendar for iOS (Swift 5.0)
Stars: ✭ 429 (+3200%)
Mutual labels:  date-time
Swiftdate
🐔 Toolkit to parse, validate, manipulate, compare and display dates, time & timezones in Swift.
Stars: ✭ 6,661 (+51138.46%)
Mutual labels:  date-time
Bottomsheetpickers
Third-party date and time pickers for Android.
Stars: ✭ 1,099 (+8353.85%)
Mutual labels:  date-time
ts-business-time
Business time / market hours logic for TypeScript
Stars: ✭ 18 (+38.46%)
Mutual labels:  date-time
timechange
Efficient Updating of Date-Times
Stars: ✭ 25 (+92.31%)
Mutual labels:  date-time
Date Info
API to let user fetch the events that happen(ed) on a specific date
Stars: ✭ 7 (-46.15%)
Mutual labels:  date-time
Pytime
PyTime is an easy-use Python module which aims to operate date/time/datetime by string.
Stars: ✭ 140 (+976.92%)
Mutual labels:  date-time
Ciso8601
Fast ISO8601 date time parser for Python written in C
Stars: ✭ 455 (+3400%)
Mutual labels:  date-time
Lubridate
Make working with dates in R just that little bit easier
Stars: ✭ 549 (+4123.08%)
Mutual labels:  date-time
Moment Range
Fancy date ranges for Moment.js
Stars: ✭ 1,639 (+12507.69%)
Mutual labels:  date-time
jest-mock-date-examples
Different approaches to mocking the Date in Jest tests
Stars: ✭ 22 (+69.23%)
Mutual labels:  date-time
Eztime
ezTime — pronounced "Easy Time" — is a very easy to use Arduino time and date library that provides NTP network time lookups, extensive timezone support, formatted time and date strings, user events, millisecond precision and more.
Stars: ✭ 173 (+1230.77%)
Mutual labels:  date-time
material-ui-datetimepicker
[UNMAINTAINED] Wrapper for Material UI Date and Time picker components
Stars: ✭ 32 (+146.15%)
Mutual labels:  date-time
Goodtimes
Java 8 Date/Time API enhancements for Groovy
Stars: ✭ 35 (+169.23%)
Mutual labels:  date-time
Socket-Programming-With-C
✉️ Learn Network Protocol and Network Programming
Stars: ✭ 147 (+1030.77%)
Mutual labels:  date-time
Pdd
📅 Tiny date, time diff calculator with piggybacked timers
Stars: ✭ 218 (+1576.92%)
Mutual labels:  date-time
Date Time
Date and time library for PHP
Stars: ✭ 128 (+884.62%)
Mutual labels:  date-time

Chronic

IRC

Chronic is a natural language date-time parser for the command-line.

Thumbnail Button

Dependencies

Installation

make install

Editor integration

Usage

[time = now] | chronic [format = %F %T]
  [--input | -i INPUT]
  [--days | -d DAYS] [--hours | -h HOURS] [--minutes | -m MINUTES] [--seconds | -s SECONDS]
  [--format | -f FORMAT] [--separator | -j SEPARATOR]
  [--sleep | -z]
  [--command | -x COMMAND]
  [--help]

Syntax

<time> [+|plus] [relative-time] | chronic [format]
<start-time> [..|-|→|to] <end-time> | chronic [format]
<time> [::] <relative-time> | chronic [format]

Examples

Simple:

echo today | chronic
# 2020-02-02 19:00:00

Increment a day:

echo 2020-02-02 + tomorrow | chronic '%F'
# 2020-02-03

Same with --input option:

echo 2020-02-02 | chronic '%F' --input '%s + tomorrow'
# 2020-02-03

Create a new diary:

echo 01 January to 31 December | chronic '# %F' > ~/documents/diary/2020.md

~/documents/diary/2020.md

# 2020-01-01
[…]
# 2020-12-31

Grep things to do over the next 7 days:

grep $(chronic --input 'today → 7 days' 'TODO.+%F' --separator '|')

Regex:

TODO.+2020-02-02|TODO.+2020-02-03|TODO.+2020-02-04|TODO.+2020-02-05|TODO.+2020-02-06|TODO.+2020-02-07|TODO.+2020-02-08

Set up an alarm:

echo Tomorrow 09:00 AM | chronic --sleep
mpv -shuffle ~/music

Configuration

alias p=echo
alias cr=chronic

Options

--input / -i INPUT
  Set text input (Default: %s).  You can map stdin content with %s.

--days / -d DAYS
  Configure step in days (Default: 1).

--hours / -h HOURS
  Configure step in hours.

--minutes / -m MINUTES
  Configure step in minutes.

--seconds / -s SECONDS
  Configure step in seconds.

--format / -f FORMAT
  Set text format (Default: %s).

--separator / -j SEPARATOR
  Configure separator (Default: ␤).

--sleep / -z
  Sleep for the specified time span.

--command / -x COMMAND
  Execute command when the specified time passed.  Requires --sleep.

--help
  Display a help message and quit.

References

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].