How bhavesh2105/greythr-automation works
Project type and purpose
• This is a Node.js–based CLI automation tool (“GreytHR-automation”) whose sole responsibility is to sign you into and out of the greytHR system on a schedule (9 AM sign-in, 7 PM sign-out), with overrides for “late” or manual sign-in/sign-out.
• It’s not a web app or microservice ecosystem—just a single process that runs under Node.js, reads/stores credentials, schedules tasks, and makes HTTP requests to the external greytHR service.
File structure
• Top‐level files only:
· index.js – the entry point.
· package.json / package-lock.json – dependency and script definitions.
· README.md – usage instructions.
· .gitignore – excludes node_modules, credentials, etc.
• No frontend/backend split, no subdirectories, no database server—this is a self-contained CLI utility.
README for additional insights
• Dependencies: Node.js runtime + installed NPM modules (likely commander/yargs for CLI parsing, node-cron or similar for scheduling, and axios/fetch for HTTP).
• Behavior:
· On first run, user supplies --user and --password → credentials persist locally (probably in a file like .credentials).
· Subsequent runs, the scheduler automatically signs in/out.
· --late flag toggles override behavior.