litclock

command module
v0.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 10, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

README

back-to-the-future-v2

GitHub release

Literal clock

This litclock command-line tool mainly converts numeric time to human friendly text.

Numeric Time -> Human Friendly Text:

  • 1:00 -> One o'clock
  • 13:05 -> Five past one

Service link: https://github.com/borischen0203/litclock-service

Features

  • litclock command: Be able to convert numeric time to human text.

How to use

On macOS via Homebrew:

Step1:

brew tap borischen0203/litclock

Step2:

brew install litclock

Run in Docker:

Required

  • Install docker
Run process

Step1: Pull docker image(borischen0203/litclock)

docker pull borischen0203/litclock

Step2: Run docker image as below command

docker run -it --rm borischen0203/litclock
Docker run demo
# Display the current time in the human text without input parameter
$ docker run -it --rm borischen0203/litclock
$ Seven past two

# Display the the human text with input numeric time
$ docker run -it --rm borischen0203/litclock 15:40
$ Twenty to four

Run in Local:

Required

brew install make
Run process

Step1: Clone the repo

git clone https://github.com/borischen0203/litclock.git

Step2: Use make to execute makefile run test and build

make all

Step3: Execute build file with or without parameter

./litclock
./litclock 15:40
Local run demo
# Display the current time in the human text without input parameter
$ ./litclock
$ Seven past two

# Display the human text with input numeric time
$ ./litclock 15:40
$ Twenty to four

Tech stack

  • Golang
  • Cobra
  • Docker
  • make
  • Github actions
  • shell

Todo:

  • Release cli on Homebrew

Documentation

Overview

Copyright © 2021 NAME HERE <EMAIL ADDRESS>

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL