{"id":15612477,"url":"https://github.com/euberdeveloper/einsteinify","last_synced_at":"2025-03-29T15:13:14.133Z","repository":{"id":57425853,"uuid":"350716729","full_name":"euberdeveloper/einsteinify","owner":"euberdeveloper","description":"A pip moudle that transforms every C #include absolute path to a given directory to a relative path to the .c or .h file","archived":false,"fork":false,"pushed_at":"2021-03-24T09:37:44.000Z","size":8,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-08T08:16:43.449Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","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/euberdeveloper.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}},"created_at":"2021-03-23T13:08:41.000Z","updated_at":"2021-03-24T09:37:46.000Z","dependencies_parsed_at":"2022-09-11T14:01:55.481Z","dependency_job_id":null,"html_url":"https://github.com/euberdeveloper/einsteinify","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/euberdeveloper%2Feinsteinify","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/euberdeveloper%2Feinsteinify/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/euberdeveloper%2Feinsteinify/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/euberdeveloper%2Feinsteinify/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/euberdeveloper","download_url":"https://codeload.github.com/euberdeveloper/einsteinify/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246200323,"owners_count":20739566,"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":"2024-10-03T06:43:11.491Z","updated_at":"2025-03-29T15:13:14.107Z","avatar_url":"https://github.com/euberdeveloper.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# einsteinify\nA pip moudle that transforms every C #include absolute path to a given directory to a relative path to the .c or .h file\n\n## Install\n\nYou can install einsteinify with pip:\n\n```sh\n$ pip install einsteinify\n```\n\n## Project purpose\n\nIt may happen that you have a folder with `.c` and `.h` files where some the `#include \"*.h\"` are **global paths** to respect to the root folder. This module makes them **relative paths** to the root folder.\n\n## Usage (global module)\n\n```sh\n$ einsteinify path/to/root/folder\n```\n\n## Usage (local module)\n\n```python\nfrom einsteinify import einsteinify\n\nPATH = 'path/to/root/folder'\n\neinsteinify(PATH)\n```\n\n## Result\n\nSuppose that you have a directory like this:\n\n```\nroot\n ├── main.h\n ├── other.h\n ├─\u003e services\n │   └── services.h\n └─\u003e utils\n     └── utils.h\n```\n\nWhere initially:\n\n**main.h**\n\n```c\n#include \"root/other.h\"\n#include \"root/services/services.h\"\n```\n\n**other.h**\n\n```c\n#include \"root/utils/utils.h\"\n```\n\n**utils.h**\n\n```c\n#include \"root/other.h\"\n#include \"root/services/services.h\"\n```\n\nAfter running **einsteinify** the includes would be:\n\n**main.h**\n\n```c\n#include \"./other.h\"\n#include \"./services/services.h\"\n```\n\n**other.h**\n\n```c\n#include \"./utils/utils.h\"\n```\n\n**utils.h**\n\n```c\n#include \"../other.h\"\n#include \"../services.h\"\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feuberdeveloper%2Feinsteinify","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feuberdeveloper%2Feinsteinify","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feuberdeveloper%2Feinsteinify/lists"}