{"id":29134123,"url":"https://github.com/tokiory/todo-c","last_synced_at":"2025-06-30T08:13:40.117Z","repository":{"id":299656878,"uuid":"1003748501","full_name":"tokiory/todo-c","owner":"tokiory","description":"🦤 Simple CLI utility for todo management written in C","archived":false,"fork":false,"pushed_at":"2025-06-17T16:45:49.000Z","size":0,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-17T16:51:13.949Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tokiory.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-17T15:53:48.000Z","updated_at":"2025-06-17T16:45:53.000Z","dependencies_parsed_at":"2025-06-17T17:02:19.320Z","dependency_job_id":null,"html_url":"https://github.com/tokiory/todo-c","commit_stats":null,"previous_names":["tokiory/todo-c"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tokiory/todo-c","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokiory%2Ftodo-c","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokiory%2Ftodo-c/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokiory%2Ftodo-c/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokiory%2Ftodo-c/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tokiory","download_url":"https://codeload.github.com/tokiory/todo-c/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokiory%2Ftodo-c/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262736670,"owners_count":23356152,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-06-30T08:13:38.185Z","updated_at":"2025-06-30T08:13:40.103Z","avatar_url":"https://github.com/tokiory.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Todo-C\n\nA simple, lightweight command-line todo application written in C with custom data structures and file-based storage.\n\n## Features\n\n- ✅ Create, read, update, and delete tasks\n- ✅ Mark tasks as completed\n- ✅ Persistent file-based storage\n- ✅ UUID-based task identification\n- ✅ Custom hashmap and vector implementations\n- ✅ Multiple command aliases for convenience\n\n## Architecture\n\nThe application is built with a modular architecture:\n\n- **Custom Data Structures**: Implementation of hashmap and vector from scratch\n- **Storage Layer**: File-based persistence with tab-separated values\n- **Command Processing**: Flexible command parsing with multiple aliases\n- **Adapter Pattern**: Clean separation between storage and business logic\n\n## Building\n\n### Prerequisites\n\n- CMake 3.16 or higher\n- C99 compatible compiler (GCC, Clang)\n- UUID library (`libuuid-dev` on Ubuntu/Debian, `uuid-dev` on other systems)\n\n### Build Instructions\n\n```bash\n# Clone the repository\ngit clone \u003crepository-url\u003e\ncd todo-c\n\n# Create build directory\nmkdir build\ncd build\n\n# Configure and build\ncmake ..\nmake\n\n# Run the application\n./todo-c\n```\n\n## Usage\n\n### Basic Commands\n\n```bash\n# Show help\n./todo-c help\n./todo-c h\n./todo-c -h\n./todo-c --help\n\n# Add a new task\n./todo-c add \"Buy groceries\"\n./todo-c a \"Buy groceries\"\n./todo-c -a \"Buy groceries\"\n./todo-c --add \"Buy groceries\"\n\n# List all tasks\n./todo-c ls\n./todo-c --list\n./todo-c -l\n\n# Mark a task as done\n./todo-c done \u003ctask-id\u003e\n./todo-c do \u003ctask-id\u003e\n./todo-c --done \u003ctask-id\u003e\n\n# Update a task\n./todo-c upd \u003ctask-id\u003e \"New task title\"\n./todo-c u \u003ctask-id\u003e \"New task title\"\n./todo-c --update \u003ctask-id\u003e \"New task title\"\n./todo-c -u \u003ctask-id\u003e \"New task title\"\n\n# Delete a task\n./todo-c del \u003ctask-id\u003e\n./todo-c d \u003ctask-id\u003e\n./todo-c -d \u003ctask-id\u003e\n./todo-c --del \u003ctask-id\u003e\n```\n\n## Data Storage\n\nTasks are stored in a tab-separated file (`storage.txt`) with the following format:\n```\n\u003ctask-id\u003e\\t\u003ctask-title\u003e\\t\u003cis-done\u003e\n```\n\nWhere:\n- `task-id`: UUID string\n- `task-title`: Task description\n- `is-done`: \"1\" for completed, \"0\" for pending\n\n## Project Structure\n\n```\ntodo-c/\n├── src/\n│   ├── main.c           # Entry point and command dispatch\n│   ├── command.c        # Command parsing and help\n│   ├── todo.c           # Core todo logic\n│   ├── storage.c        # File I/O operations\n│   ├── adapter.c        # Storage-Todo conversion\n│   └── lib/\n│       ├── hashmap.c    # Custom hashmap implementation\n│       └── vector.c     # Dynamic array implementation\n├── include/\n│   ├── command.h\n│   ├── todo.h\n│   ├── storage.h\n│   ├── adapter.h\n│   └── lib/\n│       ├── hashmap.h\n│       └── vector.h\n├── CMakeLists.txt       # Build configuration\n└── README.md\n```\n\n## Implementation Details\n\n### Custom Data Structures\n\n- **Hashmap**: Uses FNV1A hash function with linked list collision resolution\n- **Vector**: Dynamic array with automatic resizing (doubles capacity when full)\n\n### Error Handling\n\n- Graceful handling of missing files (creates new storage)\n- Input validation for commands\n- Proper error messages for invalid operations\n\n## Contributing\n\n1. Fork the repository\n2. Create a feature branch\n3. Make your changes\n4. Ensure all memory leaks are fixed\n5. Test thoroughly\n6. Submit a pull request\n\n## Dependencies\n\n- **libuuid**: For generating unique task identifiers\n- **CMake**: Build system\n- **Standard C Library**: Core functionality\n\n## Development Notes\n\n- Uses C99 standard\n- Debug builds include `-g -O0` flags\n- Compile commands are exported for IDE integration\n- Custom implementations prioritize learning over performance\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftokiory%2Ftodo-c","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftokiory%2Ftodo-c","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftokiory%2Ftodo-c/lists"}