8000 GitHub - jnorthr/CopyTools: Utility JVM Logic to Copy Text To/From System Clipboards
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

jnorthr/CopyTools

Repository files navigation

CopyTools


Important
Travis Build Status for Master Branch: Build Status (Travis CI)

Purpose

A Gradle project for Groovy users who need utility code to copy text strings to/from system clipboards. Clone includes gradle build tool wrapper and folder structure like maven/gradle so you don’t need an installed gradle build tool.

Pre-requisites
  1. Working internet connection

  2. Installed Git client to copy/clone this repo

  3. Ability to use terminal console

Steps
  1. Open terminal console

  2. Change directory \( cd \) into target folder location

  3. Run this command to create a folder and copy down all the pieces :

    git clone https://github.com/jnorthr/CopyTools.git
  4. cd CopyTools/

  5. ./gradlew runs defined tasks to build and test code samples

  6. After prior step completes, examine CopyTools/ folder to find the /build/ folder with test results


Usage Notes

The Copier.groovy source has methods to interact with the System Clipboard of most O/S types.

Put text on System Clipboard

Method Layout
public void copy(String s)

This is a class method to do the deed. Call this method with a Java/Groovy or JVM language String types to place that string on to the System Clipboard of the operating system. Only String copies are supported.

Method Sample
Copier ck = new Copier();
       ck.copy("Hi from me");

Get Text from System Clipboard

Method Layout
public String paste()

This is a class method to do the deed. Call this method with a Java/Groovy or JVM language to receive a String type from System Clipboard of the operating system. Only String copies are supported.

Method Sample
Copier ck = new Copier();
def what = ck.paste();

Other Modules

Further groovy scripts

About

Utility JVM Logic to Copy Text To/From System Clipboards

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
0