Commit Graph

344 Commits

Author SHA1 Message Date
DTB
691e94c0c1
dj(1): error reporting more of the time 2024-07-07 20:33:54 -06:00
cf744efc1b
swab(1): fixes not using strerror(3) 2024-07-07 18:21:48 -06:00
DTB
bab3cdd90e
dj(1): Io_write: don't add to bufuse 2024-07-07 18:14:48 -06:00
DTB
abfe7046e7
dj(1): fix some type issues 2024-07-05 08:02:09 -06:00
DTB
6ed7089b25
dj(1): statistics now track hard seeks 2024-07-04 21:32:05 -06:00
DTB
9e8b82c4bb
dj(1): fix inaccurate statistics after Io_read and Io_write 2024-07-04 20:47:30 -06:00
DTB
906eb92f5a
dj(1): (broken) move hard skipping to the main loop 2024-07-04 20:27:31 -06:00
DTB
9f420131ee
dj(1): more work adapting hard skipping to the main loop 2024-07-04 20:16:54 -06:00
DTB
1fab60d779
dj(1): no more pointer arithmetic 2024-07-04 20:05:18 -06:00
DTB
fe175cab19
dj(1): add a variable for skipping in the main loop 2024-07-04 20:00:40 -06:00
DTB
8c33f0116c
dj(1): move open(2) flags, remove unnecessary comments 2024-07-04 19:45:53 -06:00
DTB
f8c0e0570c
dj(1): make Io_write handle prec and rec 2024-07-04 19:36:32 -06:00
DTB
fc0d9e374b
dj(1): make printio fprintio 2024-07-04 19:23:09 -06:00
DTB
f49a2d2eb8
dj(1): move prec and rec adjustment into Io_read 2024-07-04 19:21:40 -06:00
DTB
4004a4a006
dj(1): use the retvals of Io_read and Io_write 2024-07-04 18:41:20 -06:00
DTB
cc64561388
dj(1): only include sysexits if they aren't defined 2024-07-03 20:52:41 -06:00
DTB
5b1d4fef88
dj(1): remove Io_fdopen 2024-07-03 19:22:34 -06:00
DTB
2b593559af
dj(1): remove Io_bufrpad 2024-07-03 19:06:59 -06:00
DTB
b74160fa4e
dj(1): remove Io_bufxfer 2024-07-03 19:04:01 -06:00
DTB
3e1735f778
dj(1): clean up some stray ends 2024-07-03 18:44:42 -06:00
DTB
2167f35f58
dj(1): fix segfault when bses are mismatched 2024-07-03 17:59:21 -06:00
DTB
f4b97be1f1
dj(1): iron out Io_bufxapp 2024-07-03 17:50:04 -06:00
DTB
944feef434
dj(1): Refactor out Io_fdseek entirely 2024-07-03 16:07:02 -06:00
DTB
66ca4b9a12
dj(1): remove unnecessary stderr checks 2024-07-03 15:47:48 -06:00
DTB
3897f44cf8
dj(1): prefix getopt optstring with : 2024-07-03 15:46:11 -06:00
DTB
6548a448c7
dj(1): fix potential skip/seek bug in non-std io 2024-07-03 15:44:42 -06:00
DTB
aff658d611
dj(1): remove debugging vestige, reflow output into printio 2024-07-03 14:50:50 -06:00
DTB
76252305f9
dj(1): remove Io_bufalloc 2024-07-03 14:46:56 -06:00
DTB
1cf67af281
dj(1): add a ton of assertions, fix if statement, fix io[i] mixups 2024-07-03 14:22:23 -06:00
DTB
064abb82a6
dj(1): fix option parsing regression 2024-07-03 13:50:24 -06:00
DTB
69510d76af
Merge branch 'main' into dj 2024-06-29 19:23:03 -06:00
881df1bb18
Merge branch 'usage-text' 2024-06-29 17:20:19 -06:00
cf5136d247
Makefile, swab(1): fixes swab build 2024-06-29 07:49:47 -06:00
17455baeab
intcmp(1), npc(1): removes vestigial option 2024-06-29 06:38:55 -06:00
DTB
6bd19c072d
swab(1): fix some silly mistakes 2024-06-29 06:02:39 -06:00
07a12ba81c
docs, src: fixing man page and usage text readability 2024-06-29 05:28:23 -06:00
e341c38cd6
docs, src: updates usage text for utilities 2024-06-29 05:18:20 -06:00
50bbee10a9
libgetopt.rs(3): fixes typecasting for ARM devices 2024-06-28 10:22:20 -06:00
DTB
d07bb7da41
swab(1): untested move to new getopt bindings 2024-06-28 08:33:31 -06:00
2f87ad948f
strerror.rs(3), getopt.rs(3): renames 2024-06-27 14:04:31 -06:00
DTB
3a66022c6d
dj(1): more refactor (get rid of the c scratch variable, use scoping) 2024-06-26 15:28:02 -06:00
DTB
2cfae0e8d7
dj(1): refactor (remove Io_setdefaults and other stuff) 2024-06-26 15:15:37 -06:00
DTB
fb74e7bef0
dj(1), dj.1: Remove -A (use -a "\0") (see #101) 2024-06-26 13:45:36 -06:00
DTB
e65f6b650d
dj(1): more refactor (get rid of ep pun) 2024-06-26 13:41:24 -06:00
DTB
b70b356ce5
dj(1): remove Io_buffree 2024-06-26 12:45:50 -06:00
DTB
66f5498232
dj(1): refactor Io_fdseek 2024-06-26 12:40:36 -06:00
DTB
45a880455d
dj(1): refactor to build again and to get rid of globals 2024-06-26 12:22:33 -06:00
DTB
95f7992e0f
dj(1): fix usage text to be consistent with man page 2024-06-26 11:39:34 -06:00
DTB
d3f5246242
dj(1), dj.1: remove the unnecessary -d and -q 2024-06-26 11:36:52 -06:00
6e4aeb7be7
fop(1): bring getopt(3) usage up-to-date 2024-06-23 01:00:48 -06:00
965d1bb76e
Merge branch 'main' into getopt-bindings 2024-06-23 00:57:20 -06:00
e1bf49c75a
getopt.rs(3): adds comments & documentation 2024-06-22 22:30:30 -06:00
8f990ba515
getopt.rs(3): adds testing 2024-06-22 22:18:13 -06:00
4b3333d8d3
fop(1): record separator worky now? 2024-06-21 03:26:42 -06:00
35f49a699f
fop(1): fixes record separator, again 2024-06-19 15:26:46 -06:00
40da8135f1
getopt.rs(3): relicense to AGPLv3 2024-06-06 01:03:01 -06:00
d22d90b6ec
Merge branch 'fop-delim' (closes #106) 2024-06-05 17:28:51 -06:00
3392d64e44
fop(1): literal record separator 2024-06-05 17:25:22 -06:00
02daca87dc
fop(1): updated to latest optind api 2024-06-05 11:55:16 -06:00
e862b7fec6
getopt.rs(3): safe api around optind reading and setting 2024-06-05 11:54:55 -06:00
05cde15105
fop(1): updated to use new optind api 2024-06-04 19:15:55 -06:00
35ddc729fd
getopt.rs(3): makes optind part of the Opt struct 2024-06-04 19:15:22 -06:00
b7283d54fe
getopt.rs(3): formatting & organization 2024-06-04 15:07:11 -06:00
a5a9c91cb6
getopt.rs(3): optind support 2024-06-04 15:04:01 -06:00
642774bccf
src: removed erroneous file 2024-06-02 19:21:56 -06:00
2dd6c0ded7
fop(1): adds the ability to use any string as a delimiter 2024-06-02 19:05:30 -06:00
DTB
6132c9bf47
Merge branch 'main' into scrut-sysexits 2024-04-26 19:37:34 -06:00
DTB
919b171400
scrut(1): conditionally include non-POSIX sysexits.h 2024-04-26 19:35:33 -06:00
DTB
8e38db92c7
scrut(1): update copyright header 2024-04-26 19:33:45 -06:00
DTB
adc9dbded5
scrut(1): changed return status 1 to EXIT_FAILURE 2024-04-26 19:30:33 -06:00
488351da39
scrut(1): changed return status 0 to EXIT_SUCCESS 2024-04-25 16:46:05 -06:00
78eacd660a
getopt.rs(3): better Opt return 2024-04-13 23:42:11 -06:00
d1b77d652b
getopt.rs(3): returns last parsed option 2024-04-13 17:11:04 -06:00
95927ba8c5
getopt.rs(3): formatting 2024-04-11 23:51:52 -06:00
ad92fe27d4
fop(1): switch to getopt.rs(3) 2024-04-11 23:37:04 -06:00
bb2c63bfaf
getopt.rs(3): fixed pointer shenanigans 2024-04-11 20:33:42 -06:00
88b0d55440
getopt.rs(3): refactor to remove as much as possible from unsafe 2024-04-11 20:21:01 -06:00
320a70bc56
getopt.rs(3): initial commit 2024-04-01 20:39:10 -06:00
DTB
61382c34d9
mm(1): error out when given positional arguments 2024-03-31 22:54:03 -06:00
8d9ac33566
Merge branch 'strerror' 2024-03-29 19:23:27 -06:00
d87b5d0958
hru(1), fop(1): changed to reflect strerror changes 2024-03-18 21:31:25 -06:00
1891c3e1aa
strerror(3): created strerror() method 2024-03-18 21:30:43 -06:00
127192185f
Merge branch 'dj-fix' (closes #66) 2024-03-18 21:01:48 -06:00
f81232685a
Merge branch 'mm' 2024-03-18 20:56:06 -06:00
05b5a4480c
Merge branch 'swab' (closes #22) 2024-03-18 20:53:08 -06:00
b356ac522f
strerror(3): changed panic to 0 2024-03-18 20:45:53 -06:00
8193e471f0
changes redundant .unwrap_or_else(panic!()) to .unwrap() 2024-03-03 17:26:40 -07:00
c392dbc680
Makefile: better deps; fop(1), hru(1), strerror(3): changed strerror wrapper function name 2024-03-02 10:16:32 -07:00
ca01ca4074
rpn(1): remove erroneous strerror(3) dependency 2024-03-01 23:14:58 -07:00
3e6dc5cc46
rpn(1): make error messages consistent with other tools 2024-03-01 23:14:18 -07:00
cf1d16f860
hru(1): changed to use strerror(3) 2024-03-01 23:12:44 -07:00
8f956d775c
fop(1): changed to use strerror(3) 2024-03-01 23:10:28 -07:00
e81703c6e1
sterror(3): added library for C-like error messages; Makefile: some efficiency changes 2024-03-01 23:04:53 -07:00
DTB
135bf2a8eb
mm(1), mm.1: bring source in line with documentation 2024-02-26 09:11:47 -07:00
DTB
d74bc715cf
mm(1): fix full file handling 2024-02-26 09:02:58 -07:00
DTB
bbac85daf8
swab(1): add copyright notice 2024-02-26 08:42:06 -07:00
DTB
e788947fc4
swab(1): add argument parsing 2024-02-24 03:04:05 -07:00
e6b1db3f40
Merge branch 'hru' (closes #33) 2024-02-23 22:15:43 -07:00
ef1643660b
hru(1): fixed lack of newline 2024-02-23 22:11:23 -07:00
b0636b416e
Merge branch 'fop-trim' (closes #54, closes #58) 2024-02-23 22:05:56 -07:00
bd08ef479c
hru(1): error handling tweaks 2024-02-23 21:58:23 -07:00
3cee3de900
fop(1): committing to Rust error messages 2024-02-23 21:46:50 -07:00
DTB
3f0d95fe8f
swab(1): minimum viable program 2024-02-23 20:49:24 -07:00
DTB
58245c9484
dj(1): remove function pointer hijinks (fixes #66) 2024-02-22 19:27:14 -07:00
0801d89128
hru(1): fixed kilo prefix 2024-02-18 14:49:09 -07:00
DTB
194b19f94b
mm(1): add 2024-02-17 23:43:22 -07:00
DTB
64a1a19bd8
scrut(1): fix buffer overflow in option parsing 2024-02-16 01:13:37 -07:00
448211bbe2
fop(1): better newline removal (preserves existing newlines) 2024-02-14 23:05:39 -07:00
4c663bf9dd
fop(1): closure fix 2024-02-14 22:55:28 -07:00
f8e3013563
fop(1): fixed trimming and handled unwraps (closes #58) 2024-02-14 22:53:45 -07:00
e3a0069180
hru(1): improved SI prefix logic 2024-02-14 00:07:06 -07:00
1299aefc39
hru(1): fixed overflow 2024-02-13 23:56:01 -07:00
d0205b71da
hru(1): read stdin until EOF 2024-02-13 17:48:25 -07:00
1ee668aed6
hru(1): made it actually work 2024-02-13 17:32:31 -07:00
5b364e104e
rpn(1): fixed exponentiation 2024-02-13 16:57:29 -07:00
fa686eefb9
hru(1): updated copyright year 2024-02-07 21:42:43 -07:00
be89e72c45
Makefile, hru(1): add hru(1) 2024-02-07 20:58:57 -07:00
b95b198923
rpn(1): typo 2024-02-07 19:12:31 -07:00
4e040e0021
rpn(1): added alternative representation for powers 2024-02-07 18:51:58 -07:00
d768a257a3
rpn(1): made EvaluationError struct contain exit code 2024-02-06 23:29:43 -07:00
228a0111c7
rpn(1): fixed Invalid error handling 2024-02-02 21:05:34 -07:00
4993c53080
rpn(1): re-fixed arg parsing 2024-02-02 19:17:00 -07:00
6f98fdd1d4
rpn(1): fixed expressions on one line 2024-02-02 19:13:53 -07:00
fb2a164507
rpn(1): rewrote parser for the second time 2024-02-02 15:35:36 -07:00
4cb5e8e2b0
rpn(1): better error handling 2024-02-02 14:16:49 -07:00
885f167afc
rpn(1): changes to error message 2024-02-02 13:04:57 -07:00
258881dbb2
rpn(1): minor change 2024-02-01 23:35:49 -07:00
b35f87bd27
rpn(1): code cleanup 2024-02-01 23:34:20 -07:00
e7ee75b03f
rpn(1): added From trait to CalcType 2024-02-01 23:32:37 -07:00
0d97f81f49
rpn(1): unicode subtraction, multiplication, division & code cleanup 2024-02-01 13:06:46 -07:00
b68f13acdc
rpn(1): added floor division 2024-02-01 12:38:12 -07:00
f7108245ea
rpn(1): more code cleanup 2024-02-01 10:54:28 -07:00
34b9519e03
rpn(1): code cleanup 2024-02-01 10:46:10 -07:00
5f8e90b592
rpn(1): added modulo 2024-02-01 01:26:48 -07:00
5debb9d954
rpn(1): highest possible precision 2024-02-01 01:18:13 -07:00
942e284f93
rpn(1): fixed exiting the program on EOF 2024-02-01 00:57:51 -07:00
4870f4679c
Makefile, rpn(1): add sysexits dependency 2024-02-01 00:41:27 -07:00
ab4d732aaf
rpn: initial working prototype 2024-02-01 00:24:38 -07:00
e246290bff
Merge branch 'djfix' 2024-01-31 13:56:04 -07:00
DTB
271510476c
dj(1): fix getopt optstring 2024-01-29 22:33:04 -07:00
601954a0f6
Merge branch 'dj-fixes' 2024-01-19 20:27:31 -07:00
04923fb1ad
Makefile, true(1), false(1): ported true and false back to C for simplicity and size 2024-01-15 16:53:34 -07:00
c444198efc
closed #18 2024-01-15 16:49:46 -07:00
28becbafbc
fop(1): updated copyright year and usage info 2024-01-15 16:33:51 -07:00
52def0a32d
Makefile, fop(1): added argument parsing and -d option 2024-01-15 16:30:00 -07:00
91e129b813
Makefile, getopt-rs: added getopt-rs library 2024-01-15 15:50:12 -07:00
DTB
ba7bd26fe6
dj(1): fix typos in comments 2024-01-15 13:34:30 -07:00
DTB
d25c8a64f2
dj(1): add copyright header to dj.c 2024-01-15 13:32:33 -07:00
DTB
612067890f
dj(1): interpret a '-' file name as standard input/output 2024-01-10 15:03:04 -07:00
DTB
88a66bcc01
dj(1): import from git.sr.ht/~trinity/src 2024-01-09 23:43:45 -07:00
0c2223d4fb
getopt-rs(3): added getopt library for Rust 2023-12-29 15:17:39 -07:00
f89a686d3c
fop(1): made checking argv better 2023-12-28 22:42:05 -07:00
b74bbd6c92
fop(1): finished implementing sysexits 2023-12-27 22:47:06 -07:00
3355cb3dc3
GNUmakefile, fop(1): added sysexits support 2023-12-27 22:42:50 -07:00
7eda8bb721
fop(1): working prototype 2023-12-27 15:44:19 -07:00
1dff7d7e18
Revert ".editorconfig: fixed utf8 issue"
This reverts commit d20a1da6f8.
2023-12-27 15:42:27 -07:00
d20a1da6f8
.editorconfig: fixed utf8 issue 2023-12-27 15:40:31 -07:00
94ba336ee4
GNUmakefile, intcmp(1), npc(1), scrut(1), str(1), strcmp(1), include/sysexits.h: added fallback header file for when systems don’t have sysexits.h(3) 2023-12-25 21:50:45 -07:00
74d5b65f78
Merge branch 'nosysexits' 2023-12-25 19:04:44 -07:00
3249a83861
Merge branch 'rmlibfileis' 2023-12-25 19:02:00 -07:00
a675386fe3
true(1): ported to Rust 2023-12-25 18:59:46 -07:00
DTB
de304b7ef7
remove libfileis(3) 2023-12-25 17:49:05 -07:00
DTB
324328d2cc
false(1): rewrite from C to Rust 2023-12-25 17:05:19 -07:00
DTB
8e330d8a63
strcmp(1): without <sysexits.h> fall back to ANSI C 2023-12-25 15:58:47 -07:00
DTB
d4ee9bb93b
str(1): without <sysexits.h> fall back to ANSI C 2023-12-25 15:58:24 -07:00
DTB
52d150b02b
scrut(1): without <sysexits.h> fall back to ANSI C 2023-12-25 15:58:08 -07:00
DTB
1bc574eafa
npc(1): without <sysexits.h> fall back to ANSI C 2023-12-25 15:57:58 -07:00
DTB
cee6575a57
intcmp(1): without <sysexits.h> fall back to ANSI C 2023-12-25 15:56:38 -07:00
20a574ca2d
str(1): fixed copyright information 2023-12-24 18:09:36 -07:00
b2759f1642
str(1): added copyright information 2023-12-24 18:08:06 -07:00
2c716f1881
str(1): fixed integer overflow 2023-12-24 18:01:15 -07:00
ef1416cd42
intcmp(1): new tool; npc(1): new tool; scrut(1): new tool; str(1): new tool; strcmp(1): new tool; tests: added POSIX compatibility test and C compiler compatibility test; Makefile: converted to GNUmakefile; README: added README; docs: added docs 2023-12-24 17:13:17 -07:00
b1f6caaf41
tail(1p): added copyright information 2023-08-30 19:11:57 -06:00
26bbb05777
tail(1p): tail -n 2023-08-30 19:09:53 -06:00
94537bc948
tail(1p): fixed file reading 2023-08-30 19:08:11 -06:00
7936ce26a0
tail(1p): trying from scratch 2023-08-30 19:01:07 -06:00
0e4faead44
tail(1p): segfaults for some reason lol 2023-08-29 13:17:35 -06:00
1d2a9c2521
tail(1p): initial commit & libyac: fixed build 2023-08-28 23:15:08 -06:00
7f5e532216
moved file resolution code to a shared library 2023-08-28 23:03:33 -06:00
3a410edddc
cat(1p): fixed storing EOF in buffer 2023-08-28 16:03:36 -06:00
6c73ffadd6
cat(1p): formatting 2023-08-14 12:08:03 -06:00
3c7d4c41be
cat(1p): minor cleanup 2023-08-14 12:04:16 -06:00
f041ae5d63
cat(1p): cleanup 2023-08-14 11:45:43 -06:00
0c290646ec
cat(1p): trimming size 2023-08-14 00:25:10 -06:00
96d692d26e
cat(1p): print errors to stderr 2023-08-14 00:17:09 -06:00
dd584b2886
cat(1p): minor typo 2023-08-14 00:07:03 -06:00
ede0817cbd
minor changes to license headers and to compilation 2023-08-14 00:01:29 -06:00
b57a7179a5
cat(1p): refactor to get no args working 2023-08-13 23:30:03 -06:00
da2ebdb1e1
cat(1p): small reformatting 2023-08-10 20:10:30 -06:00
e530f10cd5
cat(1p): fixed write buffering 2023-08-10 15:34:02 -06:00
b360b823ac
cat(1p): made simpler, added error handling 2023-08-10 15:24:07 -06:00
c8d6e9f5e4
cat(1p): fix unbuffered output 2023-08-07 20:38:57 -06:00
9adde985d9
fixed segfault 2023-07-24 09:01:41 -06:00
bb099036fb cat(1p), true(1p), false(1p): added source files & Makefile 2023-07-24 03:57:46 +00:00