Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

github.com/tignioj/go-clipboard-share

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/tignioj/go-clipboard-share

  • v0.0.0-20210416181553-4a8c0b80645f
  • Source
  • Go
  • Socket score

Version published
Created
Source

Clipboard Share

Share your clipboard text to local network.

Usage

S1 clone this repo

git clone https://github.com/tignioj/go-clipboard-share.git

S2 build source code

cd go-clipboard-share
go build

After executing the command above, you will see go-clipboard-share.exe in this directory.

S3 Run it.

  • Double click go-clipboard-share.exe
  • Open http://localhost:9999

Argument

list

  • -p: Listen port. default 9999
  • -h: Show help

example

Set listen port to 8080

./go-clipboard-share.exe -p 8080

API

/get Get server clipboard text raw string

  • Request method: GET

example:

/set Set server clipboard text

  • Request method: POST
  • Content-Type: application/x-www-form-urlencoded
  • Date-format: key=value Ajax example:
    var xhr = new XMLHttpRequest()
    xhr.open("POST", "/set")
    xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
    var data = "contentToSet=" + yourTextToSet
    xhr.send(data)
    xhr.onreadystatechange = function () {
        if (xhr.readyState === 4 && xhr.status === 200) {
            showInfo(xhr.responseText)
        }
    }

NOTICE

  • These two files index.html and help.json are not required, it just a template fo test. I have already set it to go source code as variable.

THANKS

FAQs

Package last updated on 16 Apr 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc