{"id":15693914,"url":"https://github.com/magicdawn/simple-mac-clipboard","last_synced_at":"2025-04-30T06:05:56.819Z","repository":{"id":42431557,"uuid":"243918306","full_name":"magicdawn/simple-mac-clipboard","owner":"magicdawn","description":"simple mac clipboard for node \u0026 electron","archived":false,"fork":false,"pushed_at":"2025-01-13T11:07:04.000Z","size":506,"stargazers_count":8,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-22T09:34:52.138Z","etag":null,"topics":["clip","clipboard","mac-clipboard"],"latest_commit_sha":null,"homepage":null,"language":"Objective-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/magicdawn.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2020-02-29T06:39:11.000Z","updated_at":"2025-01-13T11:07:08.000Z","dependencies_parsed_at":"2024-07-06T15:23:16.919Z","dependency_job_id":"a29cd464-5d6b-4cc2-9d9e-e608b4b25acf","html_url":"https://github.com/magicdawn/simple-mac-clipboard","commit_stats":{"total_commits":42,"total_committers":1,"mean_commits":42.0,"dds":0.0,"last_synced_commit":"c9351ea6005e041e29c187ca2ae36e857ee32fcf"},"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/magicdawn%2Fsimple-mac-clipboard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/magicdawn%2Fsimple-mac-clipboard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/magicdawn%2Fsimple-mac-clipboard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/magicdawn%2Fsimple-mac-clipboard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/magicdawn","download_url":"https://codeload.github.com/magicdawn/simple-mac-clipboard/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246320200,"owners_count":20758410,"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":["clip","clipboard","mac-clipboard"],"created_at":"2024-10-03T18:50:10.871Z","updated_at":"2025-03-30T13:14:10.471Z","avatar_url":"https://github.com/magicdawn.png","language":"Objective-C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# simple-mac-clipboard\n\n\u003e simple mac clipboard for node \u0026amp; electron\n\n[![npm version](https://img.shields.io/npm/v/simple-mac-clipboard.svg?style=flat-square)](https://www.npmjs.com/package/simple-mac-clipboard)\n[![npm downloads](https://img.shields.io/npm/dm/simple-mac-clipboard.svg?style=flat-square)](https://www.npmjs.com/package/simple-mac-clipboard)\n[![npm license](https://img.shields.io/npm/l/simple-mac-clipboard.svg?style=flat-square)](http://magicdawn.mit-license.org)\n\n## Install\n\n```sh\n$ npm i -S simple-mac-clipboard\n```\n\n## Related\n\nhttps://github.com/electron/electron/issues/9035\n\n## API\n\n\u003e based on https://developer.apple.com/documentation/appkit/nspasteboard\n\n```js\nconst clip = require('simple-mac-clipboard')\n```\n\n### Note\n\n- for read \u0026 write, format is required, and format is always the **first** argument\n- for write, the boolean return value is for success or not, map from objc `YES` or `NO`\n\n### `clear`\n\n```ts\nexport function clear(): void\n```\n\nclear the clipboard\n\n### readBuffer \u0026 writeBuffer\n\n```ts\nexport function readBuffer(format: string): Buffer\nexport function writeBuffer(format: string, data: Buffer): boolean\n```\n\nread or write `Buffer` from/to the clipboard\n\n### readText \u0026 writeText\n\n```ts\nexport function readText(format: string): string\nexport function writeText(format: string, text: string): boolean\n```\n\nread or write text from/to the clipboard\n\n## Changelog\n\n[CHANGELOG.md](CHANGELOG.md)\n\n## License\n\nthe MIT License http://magicdawn.mit-license.org\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmagicdawn%2Fsimple-mac-clipboard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmagicdawn%2Fsimple-mac-clipboard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmagicdawn%2Fsimple-mac-clipboard/lists"}