{"id":18637551,"url":"https://github.com/justin-marian/void-verse","last_synced_at":"2025-11-04T14:30:28.755Z","repository":{"id":228868580,"uuid":"773523042","full_name":"justin-marian/void-verse","owner":"justin-marian","description":"Void data pointers manager for dedications by value, managing: insertion, deletion, finding, and printing operations.","archived":false,"fork":false,"pushed_at":"2024-03-20T22:02:06.000Z","size":29,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-27T09:12:22.736Z","etag":null,"topics":["c","cmd-parser","dynamic-memory-management","void-pointers"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/justin-marian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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}},"created_at":"2024-03-17T22:04:06.000Z","updated_at":"2024-03-20T22:05:50.000Z","dependencies_parsed_at":"2024-03-20T22:09:52.063Z","dependency_job_id":null,"html_url":"https://github.com/justin-marian/void-verse","commit_stats":null,"previous_names":["justin-marian/void-verse"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justin-marian%2Fvoid-verse","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justin-marian%2Fvoid-verse/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justin-marian%2Fvoid-verse/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justin-marian%2Fvoid-verse/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/justin-marian","download_url":"https://codeload.github.com/justin-marian/void-verse/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239433910,"owners_count":19637806,"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":["c","cmd-parser","dynamic-memory-management","void-pointers"],"created_at":"2024-11-07T05:36:43.537Z","updated_at":"2025-11-04T14:30:28.699Z","avatar_url":"https://github.com/justin-marian.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Void Verse\r\n\r\nThis project is a simple void data pointers manager designed to streamline the process of commands. It allows to categorize dedications based on the value amount in the ***dedication***, recording both the name of the dedicator and the dedicatee. The program handles `insertion`, `deletion`, `finding`, and `printing` of dedications.\r\n\r\n## Structures and Storage\r\n\r\n### `head`\r\n\r\n- `type`: The type of data stored.\r\n- `len`: Total length of the data.\r\n\r\n### `data_structure`\r\n\r\n- `header`: Pointer to the header of the data.\r\n- `data`: Pointer to the actual data.\r\n\r\nData will be stored diversely using types from the `\u003cinttypes.h\u003e` header. The format for storing data depends on the type specified in the header:\r\n\r\nFor printing various integer types, **special macros** need to be used:\r\n\r\n```c\r\n    printf(\"%\"PRId8\"\\n\", val) // where val is an int8_t\r\n    printf(\"%\"PRId16\"\\n\", val) // where val is an int16_t\r\n    printf(\"%\"PRId32\"\\n\", val) // where val is an int32_t\r\n```\r\n\r\n## Usage\r\n\r\nThe program reads commands from the standard input until the `\"exit\"` command is received.\r\n\r\nBelow are the supported commands:\r\n\r\n`exit`: Terminates the program after deallocating memory.\r\n\r\n- The program cleans up allocated memory and gracefully exits.\r\n\r\n`add_last`: Adds a dedication to the end of the vector.\r\n\r\n- Appends a **new dedication** to the end of the vector and increases length.\r\n\r\n`add_at`: Inserts a dedication at a specified `index` in the vector.\r\n\r\n- It inserts a **dedication** at a specified index in the vector, ensuring that the index is not out of bounds.\r\n\r\n`find`: Retrieves and displays the **dedication** at a specified `index`.\r\n\r\n- Displays the dedication at the specified index in the vector.\r\n\r\n`delete_at`: Deletes the **dedication** at a specified `index` from the vector.\r\n\r\n- Removes the dedication at the specified index from the vector and the remaining elements are properly shifted.\r\n\r\n`print`: Prints **all dedications** in the vector.\r\n\r\n- Prints each dedication according to the specified format.\r\n\r\n```bash\r\n    Type \u003ctype header\u003e\r\n    \u003cFirst Name\u003e pentru \u003cSecond Name\u003e\r\n    \u003cFirst Banknote Value\u003e\r\n    \u003cSecond Banknote Value\u003e\r\n    (space after each printed element)\r\n```\r\n\r\n## Memory Management\r\n\r\nMemory management is crucial for the project's success. It consists of two main parts:\r\n\r\n1) **Correct Memory Allocation**: Memory should be dynamically allocated for all strings and structures used.\r\n   - Static declarations **ARE NOT PERMITED**.\r\n2) **Proper Memory Deallocation**: Memory should be deallocated correctly and completely.\r\n   - It should not display any invalid reads or memory leaks. Errors related to redirection will not be penalized.\r\n\r\nTo ensure proper memory management, Valgrind will be used for memory leak detection and debugging. The following command can be used to run Valgrind:\r\n\r\n```bash\r\nvalgrind –leak-check=full –show-leak-kinds=all –track-origins=yes ./main\r\n```\r\n\r\nA predefined test command `make check` is available to ease the testing process.\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustin-marian%2Fvoid-verse","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjustin-marian%2Fvoid-verse","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustin-marian%2Fvoid-verse/lists"}