{"id":22963439,"url":"https://github.com/kettek/node-desktop-app-settings","last_synced_at":"2026-05-08T19:31:37.664Z","repository":{"id":95261826,"uuid":"202525089","full_name":"kettek/node-desktop-app-settings","owner":"kettek","description":"Module providing multi-platform application settings with automatic saving and creation.","archived":false,"fork":false,"pushed_at":"2020-03-12T08:30:13.000Z","size":20,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-24T15:56:04.042Z","etag":null,"topics":["app","configuration","electron","nodejs","nwjs","settings"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kettek.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"COPYING","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":"2019-08-15T10:55:32.000Z","updated_at":"2020-03-12T08:30:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"903aac22-fd9a-4520-adc4-e746decfb616","html_url":"https://github.com/kettek/node-desktop-app-settings","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/kettek/node-desktop-app-settings","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kettek%2Fnode-desktop-app-settings","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kettek%2Fnode-desktop-app-settings/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kettek%2Fnode-desktop-app-settings/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kettek%2Fnode-desktop-app-settings/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kettek","download_url":"https://codeload.github.com/kettek/node-desktop-app-settings/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kettek%2Fnode-desktop-app-settings/sbom","scorecard":{"id":556601,"data":{"date":"2025-08-11","repo":{"name":"github.com/kettek/node-desktop-app-settings","commit":"38fd56481557bc139321e4b07f5cb4d9b0fd5f3e"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/5 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: COPYING:0","Info: FSF or OSI recognized license: GNU Lesser General Public License v3.0: COPYING:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-20T12:31:48.862Z","repository_id":95261826,"created_at":"2025-08-20T12:31:48.862Z","updated_at":"2025-08-20T12:31:48.862Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32794569,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-08T08:22:46.396Z","status":"ssl_error","status_checked_at":"2026-05-08T08:22:45.650Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["app","configuration","electron","nodejs","nwjs","settings"],"created_at":"2024-12-14T19:35:10.520Z","updated_at":"2026-05-08T19:31:37.639Z","avatar_url":"https://github.com/kettek.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# node-desktop-app-settings\nThis npm module provides generic desktop application settings for Linux, Mac OS, and Windows. It runs synchronously for reading and writing. It automatically loads a settings JSON file on invocation and saves the file when node exits.\n\n## Usage\nUsage is fairly simple:\n\n    let ndas = require('node-desktop-app-settings')\n    \n    let myConfig = ndas('MyProgramName')\n    \n    myConfig.settings.myOption = 123;\n\nAfter this, whether from Ctrl-C, sigs, or regular closing of the program, the data file will be saved to `USERDATA/settings.json`.\n\n### API\n\n#### NDAS(\u003cString\u003e, [options])\n`require('node-desktop-app-settings')` returns a function that is used to create a desired settings.\n\n##### options\nAn options object can optionally be passed to the NDAS constructor. The possible options are:\n\n  * `saveOn`: `[\"exit\", \"SIGINT\", \"unhandledException\"]`\n    * Setting this to an empty array will prevent any sort of saving on program exit.\n  * `appData`: `\u003cString\u003e`\n    * Manually override the default appData location.\n  * `userData`: `\u003cString\u003e`\n    * Manually override the default userData location.\n  * `settingsPath`: `\u003cString\u003e`\n    * Manually override the default settings path.\n  \n##### Example\n```\nlet ndas = require('node-desktop-app-settings')\nlet myConfig = ndas('MyProgram')\n```\n---\n```\nlet myConfig = require('node-desktop-app-settings')('MyProgram')\n````\n\n#### config.settings\nThis property is the object that is saved on a call to `save()` or program exit. If `options.saveOn` is set to an empty array, this will not automatically by saved.\n\n#### config.appData\nThis property returns:\n\n  * MacOS: /Users/user/Library/Preferences\n  * Linux: /home/user/.local/share\n  * Windows 8+: C:\\Users\\user\\AppData\\Roaming\n  * Windows XP: C:\\Documents and Settings\\user\\Application Data\n  \n**NOTE**: This uses the APPDATA or HOME environment variables along with some OS detection. See source for details.\n\n#### config.userData\nThis property returns the appData path with the first argument passed to `ndas()`.\n\n##### Example\n```\nlet myConfig = require('node-desktop-app-settings')('MyProgram')\n\nconsole.log(myConfig.userData) // returns appData + \"/MyProgram\"\n```\n\n#### config.settingsPath\nThis property returns the corresponding `settings.json` file path.\n\n##### Example\n```\nlet myConfig = require('node-desktop-app-settings')('MyProgram')\n\nconsole.log(myConfig.settingsPath) // returns userData + \"/settings.json\"\n```\n\n#### config.save()\nSaves the settings synchronously.\n\n##### Example\n```\nmyConfig.save()\n```\n\n#### config.clear()\nClears the current settings to an empty state.\n\n##### Example\n```\nmyConfig.close()\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkettek%2Fnode-desktop-app-settings","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkettek%2Fnode-desktop-app-settings","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkettek%2Fnode-desktop-app-settings/lists"}