{"id":22645761,"url":"https://github.com/voldien/exceptcxx","last_synced_at":"2025-04-12T00:34:15.792Z","repository":{"id":92126027,"uuid":"406276846","full_name":"voldien/exceptcxx","owner":"voldien","description":"Universal C++ Exception Library with StackTrace Builtin and Unicode Text Support","archived":false,"fork":false,"pushed_at":"2024-11-17T12:29:03.000Z","size":104,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-25T20:21:23.417Z","etag":null,"topics":["cross-platform","cxx11","exception","exception-messages","stacktrace"],"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/voldien.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":"2021-09-14T07:58:50.000Z","updated_at":"2024-12-24T19:03:10.000Z","dependencies_parsed_at":"2024-01-19T13:55:31.086Z","dependency_job_id":"0bd349f0-9acd-4e9f-8023-db0bda248c5c","html_url":"https://github.com/voldien/exceptcxx","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voldien%2Fexceptcxx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voldien%2Fexceptcxx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voldien%2Fexceptcxx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/voldien%2Fexceptcxx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/voldien","download_url":"https://codeload.github.com/voldien/exceptcxx/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248501700,"owners_count":21114676,"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":["cross-platform","cxx11","exception","exception-messages","stacktrace"],"created_at":"2024-12-09T06:07:12.212Z","updated_at":"2025-04-12T00:34:15.765Z","avatar_url":"https://github.com/voldien.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ExecptCXX\n\n[![ExceptCxx](https://github.com/voldien/exceptcxx/actions/workflows/ci.yml/badge.svg)](https://github.com/voldien/exceptcxx/actions/workflows/ci.yml)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n[![GitHub release](https://img.shields.io/github/release/voldien/exceptcxx.svg)](https://github.com/voldien/exceptcxx/releases)\n\nA simple library for adding universal exceptions more additional meta than the common _std::exception_ while preserving the original code when integrating.\n\n## Features\n\n* StackTrace - Support to get the stack tree of when it was invoked.\n* Unicode - Allow support for both ASCII, Unicode 8, and unicode 16.\n* Backward compadible with standard exception.\n\n## Motivation\n\nAttempt to create a dedicated Exception library with useful debug info and stack trace info while maintaining the standard c++ exception. Allowing to reuse the code in multiple projects with a good level of information when the exception is thrown.\n\n## Installation\n\nThe library can be built simply by the following commands.\n\n```bash\nmkdir build\ncd build\ncmake ..\nmake\n```\n\nA note, this exception library is using external submodule git. Use the following command to download all the dependent git repositories.\n\n```bash\ngit submodule update --init --recursive \n```\n\n## Integration with CMake\n\nThe idea is to be able to integrate this library with another project easily. With CMake, it basically requires 2 lines. One for adding the project and the second for adding it as a dependent linked library target.\n\n```cmake\nADD_SUBDIRECTORY(exceptCXX EXCLUDE_FROM_ALL)\n```\n\n```cmake\nTARGET_LINK_LIBRARIES(myTarget PUBLIC cxxexcept)\n```\n\n## Dependencies\n\nThe dependices currently is related to backward-cpp\n\n```bash\napt install binutils-dev\n```\n\n## Examples\n\nThe following is a simple example for throwing an exception, followed by printing a formated\nerror message to stdout.\n\n```cpp\ntry {\n    throw cxxexcept::DivideByZeroException();\n} catch (const std::exception \u0026ex) {\n    cxxexcept::printStackMessage(ex);\n}\n\n```\n\nAnother example, using a more common exception type, runtime exception.\n\n```cpp\ntry {\n    throw cxxexcept::RuntimeException();\n} catch (const std::exception \u0026ex) {\n     cxxexcept::printStackMessage(ex);\n}\n\n```\n\nGetting a comprehensive string of both the stack as well the cause of exception can be extracted with the following method.\n\n```cpp\nstd::cerr \u003c\u003c cxxexcept::getStackMessage(ex);\n```\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoldien%2Fexceptcxx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvoldien%2Fexceptcxx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoldien%2Fexceptcxx/lists"}