Skip to content

A nodejs addon, read or write file paths for clipboard, supports win32 and mac osx.

License

Notifications You must be signed in to change notification settings

alex8088/clipboard-files

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

clipboard-files

A nodejs addon, read or write file paths for clipboard, supports win32 and mac osx.

Install

npm i clipboard-files

Building for Electron

npm i clipboard-files --build-from-source --runtime=electron --target=24.0.0 --target_arch=ia32 --dist-url=https://electronjs.org/headers

Usage

const clipboard = require('clipboard-files')

// for mac
clipboard.writeFiles(['/Users/Alex/Download/helloWorld.js'])

// for win32
clipboard.writeFiles(['C:\\Users\\Alex\\Documents\\helloWorld.js'])

let fileNames = clipboard.readFiles()