Commit Graph

45 Commits (cygwin)

Author SHA1 Message Date
BodgeMaster c9b56d4d7f tools/dumpnbt: Remove unused CLI flag 2022-10-28 02:45:25 +02:00
BodgeMaster b5c18cd0de tools/hexnet: Implement bi-directional communication 2022-10-23 01:48:47 +02:00
BodgeMaster a1ba08b7db tools/hexnet: Shut down connections when gracefully handling signals 2022-10-23 01:47:44 +02:00
BodgeMaster 1d7e98d0b3 tools/hexnet: Implement function for reading bytes from stdin 2022-10-23 01:45:59 +02:00
BodgeMaster a7e07d2c3c tools/hexnet: Implement UDP support (and minor refactoring) 2022-10-22 18:51:29 +02:00
BodgeMaster 7ae843039c tools/hexnet: Implement TCP v6 handler, rename readFromTCPSocket to readFromTCP 2022-10-22 01:18:44 +02:00
BodgeMaster 5574cdb4bf tools/hexnet: Don’t confuse users 2022-10-22 01:02:00 +02:00
BodgeMaster 89cfb9d850 tools/hexnet: Reduce redundant code 2022-10-21 23:01:03 +02:00
BodgeMaster f681c54c82 tools/hexnet: Reimplement TCP server, implement TCP client
Both can only receive at the moment as we still don’t handle input.
2022-10-21 23:01:03 +02:00
BodgeMaster ee0ebb273c tools/hexnet: Add instructions for setting up TTY 2022-10-21 23:01:03 +02:00
BodgeMaster ee9b5d4f67 tools/hexnet: Add command line parser back
Reimplementation has started.
2022-10-19 15:26:38 +02:00
BodgeMaster b84130344d tools/hexnet: Starting over 2022-10-19 15:26:38 +02:00
BodgeMaster c14504ce0b tools/dumpnbt: Display empty lists correctly 2022-10-17 07:02:36 +02:00
BodgeMaster 92cf81c1b4 tools/dumpnbt: Implement basic functionality.
FINALLY!!! :^)
2022-10-17 06:40:56 +02:00
BodgeMaster 8d2f3f2fa5 tools/dumpnbt: Switch from using the validator to using the parser, update some strings 2022-10-16 07:40:00 +02:00
BodgeMaster b53999a548 tools/arraydump: Remove a debugging message that I accidentally left in 2022-10-08 08:32:02 +02:00
BodgeMaster 379903d751 tools/baseconvert: New tool
This tool allows for easy conversion between relevant bases
for unsigned numbers.

You may be able to coerce it into converting signed numbers into
unsigned numbers if you know how, though that is not an officially
supported use case (aka that’s using UB in the STL).
2022-10-08 08:29:01 +02:00
BodgeMaster 3b4c125ca2 tools/arraydump: Reimplement in C++ 2022-10-05 05:26:04 +02:00
Shwoomple 48f8a7dcf2 tools/hexnet: start implementing console input 2022-08-30 00:52:06 +05:30
BodgeMaster 209d0828b4 tools/hexnet: un-comment problematic sections 2022-08-29 21:06:54 +02:00
BodgeMaster b4d4ce77b2 tools/dumpnbt: better variable name and exit when data is invalid 2022-08-29 21:02:36 +02:00
BodgeMaster ee5048331c tools/dumpnbt: start implementing a preliminary version
for use until the full NBT library is in place...
2022-08-28 13:59:31 +02:00
BodgeMaster bb40f6553e tools/hexnet: comment sections out temporarily to get rid of compile errors
Doesn’t compile on Void x86_32 glibc. This will need to be investigated.
I just wanted to get rid of the errors while working on other issues.

Compile command:
ccache g++ -std=c++20 -Wall -Wextra src/tools/hexnet.cpp -I./include -Lbin/lib -l:cli.so -l:libsockpp.so -o bin/tools/hexnet
2022-08-27 11:50:36 +02:00
Shwoomple ca7b121c4d tools/hexnet: Implement udp partially. 2022-08-15 15:07:33 +05:30
BodgeMaster 8048dc8891 tools/hexnet: Put the new usage generator to use and remove prefixes for IPv4 and IPv6
The prefixes were part of a planned feature but since a connection is
either IPv4 or IPv6 but never both, it would have been completely useless
to specify which to use. Instead, only TCP and UDP will need to be specified.
2022-08-12 12:30:55 +02:00
Shwoomple cb7b5ddba7 lib/cli: Add usage generator. 2022-08-12 13:35:56 +05:30
Shwoomple e0648720bb tools/hexnet: Implement ipv6 support. 2022-08-11 22:55:12 +05:30
BodgeMaster 608767f5c2 tools/hexnet: Add more command line flags and options
This only adds the options to the parser. They aren't used anywhere in the code yet.
2022-08-02 03:42:37 +02:00
BodgeMaster 5c73308934 Rename all headers from .h++ to .hpp
Idk why I did that in the first place. Probably bc hpp looks stupid.
But having a + in a file name bugs me just as much. And other ppl as well.
So I changed it.
2022-08-02 03:35:08 +02:00
BodgeMaster b59fe1857e lib/cli: minor refactoring to make things less confusing and nicer to use
I renamed "unpositional arguments" to "options" and "positional arguments" to "arguments".
This is intended to make the code more readable and easier to type out.
2022-08-02 03:16:54 +02:00
BodgeMaster d0d02fc8d2 tools/hexnet: Move the TCP reading portion to a thread
This was too straight-forward to not just do it when I previously worked
on hexnet. Why didn't I just do it? Idk.
2022-08-02 01:07:20 +02:00
BodgeMaster adc9a7f36b tools/hexnet: prepare for multithreading
Multithreading will be needed to simultaneously receive and send data.

The preparations include:
- move all the settings of the program into global scope
- add mutexes
- move the code that reads from the TCP socket into a dedicated function
2022-07-25 15:55:40 +02:00
BodgeMaster b1733bc007 tools/hexnet: initial implementation of TCP receive only server 2022-07-20 08:06:45 +02:00
BodgeMaster efa4fa560e tools/hexnet: replace built-in argument parser with lib/cli
This is the entire reason I build lib/cli in the first place:
Parsing arguments directly in a given program tends to get really messy,
not to mention all the different ways that arguments can be specified
and the redundant work required to do that on multiple programs.
2022-07-15 13:51:19 +02:00
BodgeMaster c406555e4e tools/hexnet: argument parser fix 2022-07-13 20:35:33 +02:00
BodgeMaster 5cb1a52ec4 tools/hexnet: replace "server" with "listen" because that's what netcat calls it and the argument we use is -l like netcat's listen mode 2022-07-13 20:30:27 +02:00
BodgeMaster 9639ef065f tools/hexnet: Work on argument parser to finish suppurt for client mode 2022-07-13 20:27:58 +02:00
BodgeMaster 310011a6da tools/hexnet: replace exit codes with macros to improve readability 2022-07-13 06:06:09 +02:00
BodgeMaster 6a5096dfa3 tools/hexnet: add server/client concept to arguments parser 2022-07-13 06:03:41 +02:00
BodgeMaster b3cd8709fb Tools: Add WIP hexnet tool. This will be similar to hexdump and netcat in one.
Yes, I am using this as an exercise for myself to figure out networking.
2022-07-12 05:13:01 +02:00
BodgeMaster b0bd027898 Add license and copyright notices 2022-06-27 11:46:13 +02:00
BodgeMaster 0d10af1bd6 do not use the lib prefix for library names 2022-06-24 16:50:41 +02:00
BodgeMaster bb0dc05a30 rename header
Yes, this is a completely necessary change, I am aware.
2022-06-24 12:19:41 +02:00
BodgeMaster 6e4dd4da71 Remove build system test code, add generalized NBT model 2022-06-24 12:15:34 +02:00
BodgeMaster 0c9299b21d Create files for nbt library and a tool to use it.
These files were also used to figure out the process of building them so
their content is garbage.
2022-06-24 09:28:17 +02:00