ClipBoard checker

By ReQueST on Jan 07, 2005

Its an easy to easy snippets that allows you to check whats on your Clipboard. (CRTL+C thingy)

Usage:
/copy -m [name] --> Messages into a query to yourself, or to someone else if you specify the [name].
/copy -w filename --> Copies the total clibboard to the file. (If the file exists, if not it warns you that it cant locate the file.)
/copy -e --> Echos the clipboard into your current window.

I had some problems with the -w part, they are fixed for me, but i dont know for sure if it works for you as well.

alias copy {
  var %s = 1, %b = $cb(0)
  if ($1 == -m) {
    while (%s <= %b) {
      .msg $iif(!$2,$me,$2) $cb(%s)
      inc %s
    }
  }
  elseif ($1 == -w) {
    if ($exists($2)) {
      while (%s <= %b) {
        .write $2 $cb(%s)
        inc %s
      }
    }
    else {
      echo 12 -agt * Can't locate: $2 $+ !      
    }
  }
  elseif ($1 == -e) {
    while (%s <= %b) {
      echo 4 -agt * Clipboard: $cb(%s)
      inc %s
    }
  }
}

Comments

Sign in to comment.
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.