Files
timetracker/INSTALL_Linux.md

2.0 KiB

timetracker INSTALL

Basic Installation

Use git clone to create a local copy of the timetracker repository on your local Linux system. If you'd rather use the older, slower Python/Bash scripts, you can then copy or link the timetracker.py, do_process.sh, and chug.sh files into your path. I like to keep these in a ~/timetracker directory, where I execute them with a leading ./ so they don't need to be in my PATH variable.

If you'd prefer to use the Rust programs (which is highly recommended, if only for execution speed), you will need to compile the Rust programs with cargo (the Rust language package manager). Do the following:

  1. Install Rust language using your chosen distribution's package manager. For Arch Linux:
    pacman -Syu rust
    
  2. Navigate to the timetracker/rust/timetracking directory in the cloned timetracker source directory
  3. Execute the following command:
    cargo build --release
    
    If you are intending to debug or otherwise develop the Rust programs, I recommend creating a fork on git.eldon.me, making your proposed changes in your local clone of the fork, and then issue a PR against my parent repository. In that case you can drop the --release argument, which will keep debugging symbols and such in the executable.
  4. The compiled executables will be in the target/release or the target/debug subdirectories, depending on whether you provided --release to the build step (without this flag the executables will be in the debug subdirectory). You may copy them or link them to your PATH (e.g., ~/bin) for use.
    • Note that if you're working on a specific program in the package, you can change directory to whichever executable you're working on (chug, doprocess, timetracker, or the library package timelogging), you will likely want to run the debug version directly, like so:
      cargo run -- <input arguments>
      

Pro Tips (TODO)

  • X11/X.org macros (autokey)
  • Wayland/Hyprland macros (hyprctl dispatch/espanso)