{"id":19552460,"url":"https://github.com/pixeldroid/log-ls","last_synced_at":"2025-07-17T07:04:29.894Z","repository":{"id":141770852,"uuid":"65705703","full_name":"pixeldroid/log-ls","owner":"pixeldroid","description":"a simple logging utility for Loom, plus a handy config reader","archived":false,"fork":false,"pushed_at":"2018-05-04T02:27:17.000Z","size":192,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-14T20:51:11.339Z","etag":null,"topics":["configuration","debug","error","fatal","framework","info","json","library","logging","loomlib","loomscript","warn"],"latest_commit_sha":null,"homepage":"https://pixeldroid.com/log-ls/","language":"LoomScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pixeldroid.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":"2016-08-15T05:01:31.000Z","updated_at":"2018-05-04T02:27:19.000Z","dependencies_parsed_at":null,"dependency_job_id":"8157cdd1-193b-45a0-9150-8b5a68a93193","html_url":"https://github.com/pixeldroid/log-ls","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/pixeldroid/log-ls","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixeldroid%2Flog-ls","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixeldroid%2Flog-ls/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixeldroid%2Flog-ls/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixeldroid%2Flog-ls/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pixeldroid","download_url":"https://codeload.github.com/pixeldroid/log-ls/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixeldroid%2Flog-ls/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265575472,"owners_count":23790776,"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":["configuration","debug","error","fatal","framework","info","json","library","logging","loomlib","loomscript","warn"],"created_at":"2024-11-11T04:18:15.699Z","updated_at":"2025-07-17T07:04:29.878Z","avatar_url":"https://github.com/pixeldroid.png","language":"LoomScript","readme":"log-ls\n======\n\na simple logging utility for [Loom][loom-sdk], plus a handy config reader\n\n\u003e view the docs at https://pixeldroid.com/log-ls/\n\n- [installation](#installation)\n- [usage](#usage)\n- [building](#building)\n- [contributing](#contributing)\n\n\n## installation\n\nDownload the library into its matching sdk folder:\n\n    $ curl -L -o ~/.loom/sdks/sprint34/libs/Log.loomlib \\\n        https://github.com/pixeldroid/log-ls/releases/download/v3.0.0/Log-sprint34.loomlib\n\nTo uninstall, simply delete the file:\n\n    $ rm ~/.loom/sdks/sprint34/libs/Log.loomlib\n\n\n## usage\n\n### Log\n\n0. import `Log` (once per class)\n0. declare a label (once per class)\n0. set the log level (once at app startup, ideally from a config file value)\n0. submit a message generator at some verbosity level (`debug`, `info`, `warn`, `error`, `fatal`)\n\n```ls\npackage\n{\n    import loom.Application;\n\n    import pixeldroid.util.log.Log;\n    import pixeldroid.util.log.LogLevel;\n\n\n    public class LogTest extends Application\n    {\n        private const _logName:String = getFullTypeName();\n\n        override public function run():void\n        {\n            Log.level = LogLevel.INFO;\n            Log.info(_logName, function():String { return _logName +' is running!'; });\n        }\n    }\n}\n```\n\n### Config\n\n0. create a json file named `app.config` in the `assets/` folder of the project root\n0. import `Config`\n0. retrieve values\n\n```json\n{\n  \"app_version\": \"1.0.0\",\n  \"log_level\": \"DEBUG\",\n  \"my_string\": \"string value\",\n  \"my_number\": 123.456,\n  \"my_integer\": 789\n}\n```\n\u003e _assets/app.config_\n\n```ls\npackage\n{\n    import loom.Application;\n\n    import pixeldroid.util.config.Config;\n    import pixeldroid.util.log.Log;\n    import pixeldroid.util.log.LogLevel;\n\n\n    public class ConfigTest extends Application\n    {\n        private const _logName:String = getFullTypeName();\n\n        override public function run():void\n        {\n            Log.level = LogLevel.INFO;\n            Log.info(_logName, function():String { return 'app version: ' +Config.appVersion; });\n            Log.info(_logName, function():String { return 'log level: ' +Config.logLevel; });\n            Log.info(_logName, function():String { return 'my string: ' +Config.getString('my_string'); });\n            Log.info(_logName, function():String { return 'my number: ' +Config.getNumber('my_number'); });\n            Log.info(_logName, function():String { return 'my integer: ' +Config.getInteger('my_integer'); });\n        }\n    }\n}\n```\n\n\n## building\n\nfirst, install [loomtasks][loomtasks] and the [spec-ls library][spec-ls]\n\n### compiling from source\n\n    $ rake lib:install\n\nthis will build the Log library and install it in the currently configured sdk\n\n### running tests\n\n    $ rake test\n\nthis will build the Log library, install it in the currently configured sdk, build the test app, and run the test app.\n\n\n## contributing\n\nPull requests are welcome!\n\n\n[loom-sdk]: https://github.com/LoomSDK/LoomSDK \"a native mobile app and game framework\"\n[loomtasks]: https://github.com/pixeldroid/loomtasks \"Rake tasks for working with loomlibs\"\n[spec-ls]: https://github.com/pixeldroid/spec-ls \"a simple spec framework for Loom\"\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpixeldroid%2Flog-ls","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpixeldroid%2Flog-ls","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpixeldroid%2Flog-ls/lists"}