spicylord / clutils (public) (License: GPLv3) (since 2019-07-04) (hash sha1)
An assortment of new and rewritten preexisting tools written by me.
List of commits:
Subject Hash Author Date (UTC)
modified usage output and allowed for #,p 504ca7b3d8db60cb6d1f36a3fd48043ff62f78c0 spicylord 2019-07-06 15:49:16
spelling error in README 351dbee78173eef7ae94f9142c6a97452db0d208 spicylord 2019-07-04 20:30:33
added examples and instructions for clp, spng, and sc in the README 313a86755e40d909861bc95a11b75bbb109012c9 spicylord 2019-07-04 19:25:33
made regex slightly neater ac8eda8f7290e5f138edac12f789b1215de90719 spicylord 2019-07-04 18:31:55
fixed outputting garbled text into clipboard file a100287acf1993ae13130e036d7104bd2afe4585 spicylord 2019-07-04 18:30:34
fixed install script to compile clp.c instead of clb.c 54a54b5da1a122e69ed62bc0f030f11044a62fb9 spicylord 2019-07-04 13:47:33
added email a04151394c9a4b3afe23e8ebd11939fe7892737d spicylord 2019-07-04 02:58:00
initial commit 484a7ed27b1835a962cec85cc6f55a20d4a95b46 spicylord 2019-07-04 02:50:23
Commit 504ca7b3d8db60cb6d1f36a3fd48043ff62f78c0 - modified usage output and allowed for #,p
Author: spicylord
Author date (UTC): 2019-07-06 15:49
Committer name: spicylord
Committer date (UTC): 2019-07-06 15:49
Parent(s): 351dbee78173eef7ae94f9142c6a97452db0d208
Signing key:
Tree: 83401595a0f4d3679b131af954f667c155098aef
File Lines added Lines deleted
clp.c 9 4
File clp.c changed (mode: 100644) (index 5834d6d..2fdd5ec)
6 6
7 7 int main(int argc, char *argv[]) int main(int argc, char *argv[])
8 8 { {
9 char *usage="usage: clip [-f filename] [i,c]or[#,#(p,d)]\n";
9 10 long from=0, to=0, end=0; long from=0, to=0, end=0;
10 11 int inflag=0, outflag=0, ocountflag=0, delflag=0, commaflag=0; int inflag=0, outflag=0, ocountflag=0, delflag=0, commaflag=0;
11 12 FILE *filep; FILE *filep;
 
... ... int main(int argc, char *argv[])
19 20
20 21 if (argc>1) { if (argc>1) {
21 22 for (int i=1; argv[i]; i++) { for (int i=1; argv[i]; i++) {
22 if (argv[i][0]=='-' && argv[i][1] && argv[i][1]=='f' && argv[i+1]) {
23 if (argv[i][0]=='-'
24 && argv[i][1]
25 && argv[i][1]=='f'
26 && argv[i+1]) {
23 27 filename = argv[i+1]; filename = argv[i+1];
24 28 i++; /* makes cursor skip file name */ i++; /* makes cursor skip file name */
25 29 } }
 
... ... int main(int argc, char *argv[])
53 57 fputs("clip: must have a number before comma\n", stderr); fputs("clip: must have a number before comma\n", stderr);
54 58 exit(1); exit(1);
55 59 } }
56 if (from > to) {
60 if (to && from > to) {
57 61 fputs("clip: first number must be less than second\n", stderr); fputs("clip: first number must be less than second\n", stderr);
58 62 exit(1); exit(1);
59 63 } }
60 64 } }
61 65 } }
62 66 if (!inflag && !outflag && !delflag && !ocountflag) { if (!inflag && !outflag && !delflag && !ocountflag) {
63 fputs("usage: clip [-f filename] [justcount|in|out #,#|delete #,#]\n", stderr);
67 fputs(usage, stderr);
64 68 exit(1); exit(1);
65 69 } }
66 70 } else { } else {
67 fputs("usage: clip [-f filename] [count|in|print #,#|delete #,#]\n", stderr);
71 fputs(usage, stderr);
68 72 exit(1); exit(1);
69 73 } }
70 74
 
... ... int main(int argc, char *argv[])
101 105 } }
102 106 if (!from && !to && commaflag) { from=1; to=end; } if (!from && !to && commaflag) { from=1; to=end; }
103 107 if (!from && !to && !commaflag) { from = end; to = end; } if (!from && !to && !commaflag) { from = end; to = end; }
108 if (from && !to && commaflag) to = end;
104 109 if (delflag) { if (delflag) {
105 110 int delimflag=0; int delimflag=0;
106 111 if ((tdelfilep=fopen(".clipboard~~~", "w+"))==NULL) { if ((tdelfilep=fopen(".clipboard~~~", "w+"))==NULL) {
Hints:
Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://rocketgit.com/user/spicylord/clutils

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@ssh.rocketgit.com/user/spicylord/clutils

Clone this repository using git:
git clone git://git.rocketgit.com/user/spicylord/clutils

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a merge request:
... clone the repository ...
... make some changes and some commits ...
git push origin main