{"id":21879237,"url":"https://github.com/typpo/leafstorm","last_synced_at":"2026-05-20T07:03:25.324Z","repository":{"id":975254,"uuid":"773969","full_name":"typpo/leafstorm","owner":"typpo","description":null,"archived":false,"fork":false,"pushed_at":"2010-07-21T07:01:13.000Z","size":91,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-26T18:29:41.880Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","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/typpo.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}},"created_at":"2010-07-14T05:44:55.000Z","updated_at":"2023-05-04T14:07:21.000Z","dependencies_parsed_at":"2022-07-05T22:30:32.889Z","dependency_job_id":null,"html_url":"https://github.com/typpo/leafstorm","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/typpo%2Fleafstorm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typpo%2Fleafstorm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typpo%2Fleafstorm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typpo%2Fleafstorm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/typpo","download_url":"https://codeload.github.com/typpo/leafstorm/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244885696,"owners_count":20526296,"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-11-28T08:15:40.655Z","updated_at":"2026-05-20T07:03:20.304Z","avatar_url":"https://github.com/typpo.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"leafstorm adds macros to your C file to replace lines of code with a repeating word.\n\nHere's an example:\n\n    #include \u003cstdio.h\u003e\n    #include \u003cstdlib.h\u003e\n\n    int test(char **, char*);\n\n    int main(int argc, char **argv) {\n        if (argc == 2) {\n            printf(\"%s\\n\", ++*argv);\n        }\n\n        int i;\n        for (i=0; i \u003c 10; i++) {\n            printf(\"%d:%d\\t\", i, i % 2);\n        }\n        printf(\"\\n\");\n\n        /* int j;\n            for (j=0; j \u003c 50; j++) {\n            printf(\"%d\\n\",j );\n        }\n        */\n\n        char *a[] = {\"goat\", \"lion\", \"elephant\", 0};\n        printf(\"%d\\n\", test(a, \"animal\"));\n\n        return 0;\n    }\n\n    int test(char **x, char *c) {\n        while (*x) {\n            printf(\"%s: %s\\n\", *x, c);\n            x++;\n        }\n    }\n\nAfter running `leafstorm WA sample.c \u003e out.c`:\n\n    #define WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA x++;\n    #define WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA printf(\"%s: %s\\n\", *x, c);\n    #define WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA while (*x) {\n\t#define WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA int test(char **x, char *c) {\n\t#define WAWAWAWAWAWAWAWAWAWAWAWAWAWA return 0;\n\t#define WAWAWAWAWAWAWAWAWAWAWAWAWA printf(\"%d\\n\", test(a, \"animal\"));\n\t#define WAWAWAWAWAWAWAWAWAWAWAWA char *a[] = {\"goat\", \"lion\", \"elephant\", 0};\n\t#define WAWAWAWAWAWAWAWAWAWAWA printf(\"\\n\");\n\t#define WAWAWAWAWAWAWAWAWA printf(\"%d:%d\\t\", i, i % 2);\n\t#define WAWAWAWAWAWAWAWA for (i=0; i \u003c 10; i++) {\n\t#define WAWAWAWAWAWAWA int i;\n\t#define WAWAWAWAWAWA }\n\t#define WAWAWAWAWA printf(\"%s\\n\", ++*argv);\n\t#define WAWAWAWA if (argc == 2) {\n\t#define WAWAWA int main(int argc, char **argv) {\n\t#define WAWA void usage();\n\t#define WA int test(char **, char*);\n\t#include \u003cstdio.h\u003e\n    #include \u003cstdlib.h\u003e\n    WA\n    WAWA\n    WAWAWA\n    WAWAWAWA\n    WAWAWAWAWA\n    WAWAWAWAWAWA\n    WAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWAWA\n    WAWAWAWAWAWA\n    WAWAWAWAWAWA\n\nBeautiful!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftyppo%2Fleafstorm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftyppo%2Fleafstorm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftyppo%2Fleafstorm/lists"}