Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use the moro tool in linux

2025-03-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces how to use moro tools in linux, with certain reference value, interested friends can refer to, I hope you have a lot of harvest after reading this article, let Xiaobian take you to understand.

Moro -a command-line productivity tool for tracking working hours

Since Moro is written in NodeJS, make sure you have NodeJS installed on your system. If you don't have NodeJS installed, follow the link below to install NodeJS and NPM in your Linux.

How to install NodeJS on Linux

Once NodeJS and NPM are installed, run the following command to install Moro.

$ npm install -g moro Usage

Moro's concept of work is very simple. It keeps track of your work start time, end time and rest time on your system. At the end of each day, it will tell you how much time you have worked.

When you arrive at the office, simply type:

$ moro

Example output:

Moro \o/ You clocked in at: 9:20

Moro will register this time as your start time.

When you leave the office, type again:

$ moro

Example output:

Moro \o/ You clocked out at: 19:22 Today looks like this so far:┌──────────────────┬─────────────────────────┐│ Today you worked │ 9 Hours and 72 Minutes │├──────────────────┼─────────────────────────┤│ Clock in │ 9:20 │├──────────────────┼─────────────────────────┤│ Clock out │ 19:22 │├──────────────────┼─────────────────────────┤│ Break duration │ 30 minutes │├──────────────────┼─────────────────────────┤│ Date │ 2018-03-19 │└──────────────────┴─────────────────────────┘ Run moro --help to learn how to edit your clock in, clock out or break duration for today

Moro will register this time as your end time.

Now Moro will subtract the start time from the end time, subtract another 30 minutes from the total time as a break, and give you the total working time for the day. I'm sorry, but I'm a terrible interpreter of mathematical processes. Suppose you come to work at 10:00 a.m. and leave at 17:30 p.m. So, you spent a total of 7:30 hours in the office (e.g., 17:30-10). Then subtract the rest time from the total time (default is 30 minutes). So your total working time is 7 hours. Got it? Very good!

Note: Don't confuse "moro" with "more" as I did when I wrote this manual.

View all hours you signed up for, Run:

$ moro report --all

Just in case, if you forget to register a start time or an end time, you can also specify these values later.

For example, register 10 a.m. as the start time and run:

$ moro hi 10:00 Moro \o/ You clocked in at: 10:00 Working until 18:00 will make it a full (7.5 hours) day

Register 17:30 as the end time:

$ moro bye 17:30 Moro \o/ You clocked out at: 17:30 Today looks like this so far: ┌──────────────────┬───────────────────────┐│ Today you worked │ 7 Hours and 0 Minutes │├──────────────────┼───────────────────────┤│ Clock in │ 10:00 │├──────────────────┼───────────────────────┤│ Clock out │ 17:30 │├──────────────────┼───────────────────────┤│ Break duration │ 30 minutes │├──────────────────┼───────────────────────┤│ Date │ 2018-03-19 │└──────────────────┴───────────────────────┘ Run moro --help to learn how to edit your clock in, clock out or break duration for today

You already know Moro will subtract 30 minutes of rest by default. If you need to set a custom break, you can simply use the following command:

$ moro break 45

Now, the break is 45 minutes.

To clear all data:

$ moro clear --yes Moro \o/ Database file deleted successfully Add Notes

Sometimes, you want to add notes while working. No need to look for a standalone note-taking app. Moro will help you add notes. To add notes, simply run:

$ moro note mynotes

To search all registered notes afterwards, simply do:

$ moro search mynotes modify default settings

The default full working time is 7.5 hours. This is because the developers are from Finland, and this is the official number of hours worked. But you can also modify this setting for the number of hours worked in your country.

For example, to set it to 7 hours, run:

$ moro config --day 7

Similarly, the default rest time can be modified from 30 minutes as follows:

$ moro config --break 45 Backup your data

As I said, Moro stores time-tracking information in your home directory under the file name. moro-data.db.

However, you can save backup databases to different locations. To do this, move the. moro-data.db file to a different location of your choice and tell Moro to use that database file like this.

$ moro config --database-path /home/sk/personal/moro-data.db

In each of the above commands, I have assigned the default database file to the/home/sk/personal directory.

If you need help, run:

$ moro --help Thank you for reading this article carefully. I hope that Xiaobian will share the article "How to use moro tools in linux". This article is helpful to everyone. At the same time, I hope that everyone will support you a lot. Pay attention to the industry information channel. More relevant knowledge is waiting for you to learn!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report