Skip to content

SuneharSandhu/UniversalClipboard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Logo

UniversalClipboard

A lightweight app to copy text from a windows machine and
immediately be able to paste on all apple devices and vice versa!


Getting Started

Prerequisites

  • MacOS 13.0 or >
  • XCode
  • NodeJS

Installation

  1. Clone the repo

    git clone https://github.com/SuneharSandhu/UniversalClipboard.git
  2. On a Mac, open UniversalClipboard.xcodeproj

  3. On a windows machine, start the websocket server from terminal:

    • node server.js
      
    • You should see this:
      server

    • Download Ngrok: https://ngrok.com/download (allows clients to connect to server without being on localhost)

    • Open up another terminal and start the port forwarding:

       ngrok tcp 8080
      

      You should see something like this in the terminal:

  4. Copy the address from the forwarding line and paste that in the index.html here: socket

    Note: Prefix with ws instead of tcp here.

  5. Now in yet again another terminal, start the http server:

    http-server -p 8889 // you can use any port number here
    
  6. Open up a browser and type in localhost:8889

    • You should see 'Client connected' printed out in the server.js terminal
      web
    • Webpage UI
      html

WebClient and Server are now fully setup ✅


  1. Now open UniversalClipboard.xcodeproj in XCode on your Mac and paste the same forwarding address you pasted in index.html in the WebsocketManager.swift file

  2. Now run the project and you should see a menu bar icon at the top like so:
    Screenshot 2024-08-03 at 7 19 25 PM

    Note: If you see a slash, it means it either failed to connect to the websocket or the server isnt running.

About

Copy/Paste text between Mac and Windows!

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published