This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
HPWebcamAble's profile picture

Craft Compress

Started by HPWebcamAble, 28 February 2015 - 05:59 PM
HPWebcamAble #1
Posted 28 February 2015 - 06:59 PM
Unfortunately, I was unable to get this program to work like I wanted

I'll point you to CrazedProgrammer's version, Packager:
http://www.computerc...e__hl__compress

It ACTUALLY works - It has compression, and self extracting files
(No encryption though…)



Original Post:
Spoiler
Craft Compress



Description

This program allows you to turn a directory into a single file (and back again)

You can now make SELF EXTRACTING FILES!


Coming soon When I figure how to do it:
-Encryption
-Working Self-extracting files
-Actual compression

Download

Craft Compress 1.0:
Doesn't create self extracting files
http://pastebin.com/YbyvQDP6

Craft Compress 2.0:
Can ONLY make self extracting files
http://pastebin.com/JCCNWT8N

Type the following in a Computer (Any computer should be fine)

pastebin get <code> cc
cc stands for Craft Compress. You can change it, but the program assumes it is called cc.


How To Use

To compress a directory:

cc c <directory path> <destination path>


To decompress a file:
Version 1

cc u <file path> <destination path>


Version 2

<filename> <destination path>

Example:
I have a directory called 'secretStuff' with several files and directories inside it.

cc c secretStuff compressedSecretStuff
It would create a file called 'compressedSecretStuff' that I could then decompress if I wanted to.

Example 2:
I have a self extracting file named 'bob'

bob hi
It would create a directory called 'hi' from the files in 'bob'

Planned Features

- Encryption (Enter a password, and your files are encrypted before compression)
- ACTUAL compression (currently, the 'compressed' file is actually larger than the directory)
- UI
- ??? Leave your suggestions!

Bugs and Questions

If you find a bug, leave the error (If it had one) and a brief description of anything that you think is relevant
If you have any questions, feel free to ask

IMPORTANT NOTE (If you read this far)
There are some problems with self extracting files
It has to do with nested brackets []
I'm working on it…
Edited on 21 April 2015 - 01:54 AM
Creator #2
Posted 28 February 2015 - 07:08 PM
Really nice!!!
Geforce Fan #3
Posted 28 February 2015 - 07:30 PM
Neat!
Exerro #4
Posted 28 February 2015 - 08:17 PM
Nice idea, although I'd recommend adding self-extracting archives.
DannySMc #5
Posted 28 February 2015 - 10:41 PM
Craft Compress

Version 1.0



Description

This program allows you to turn a directory into a single file (and back again)


Download

Pastebin: http://pastebin.com/YbyvQDP6

Type the following in a Computer (Any computer should be fine)

pastebin get YbyvQDP6 cc
cc stands for Craft Compress. You can change it, but the program assumes it is called cc.


How To Use

To compress a directory:

cc c <directory path> <destination path>


To decompress a file

cc u <file path> <destination path>


Example:
I have a directory called 'secretStuff' with several files and directories inside it.

cc c secretStuff compressedSecretStuff
It would create a file called 'compressedSecretStuff' that I could then decompress if I wanted to.

Planned Features

- Encryption (Enter a password, and your files are encrypted before compression)
- UI (Maybe)
- ??? Leave your suggestions!

Bugs and Questions

If you find a bug, leave the error (If it had one) and a brief description of anything that you think is relevant
If you have any questions, feel free to ask
This is awesome! Was looking for something like this, thanks :D/> Could you upload it to my app store? as I may use this in some programs for the app store if you don't mind? Thanks!
HPWebcamAble #6
Posted 28 February 2015 - 10:57 PM
This is awesome! Was looking for something like this, thanks :D/> Could you upload it to my app store? as I may use this in some programs for the app store if you don't mind? Thanks!

I don't have time to upload it myself, but you are welcome to use it in your app store :)/>

PS you didn't have to quote my whole post…

Nice idea, although I'd recommend adding self-extracting archives.

Me gusta. Will do soon
Bomb Bloke #7
Posted 28 February 2015 - 11:00 PM
- ??? Leave your suggestions!

Compression! :P/>
HPWebcamAble #8
Posted 28 February 2015 - 11:45 PM
- ??? Leave your suggestions!

Compression! :P/>

Haha almost forgot. Yes, it doesn't really compress the files, but I guess you could say that it's still a form of compression. Added to first post.
secret6timb1 #9
Posted 01 March 2015 - 12:43 AM
Craft Compress

Version 1.0



Description

This program allows you to turn a directory into a single file (and back again)


Download

Pastebin: http://pastebin.com/YbyvQDP6

Type the following in a Computer (Any computer should be fine)

pastebin get YbyvQDP6 cc
cc stands for Craft Compress. You can change it, but the program assumes it is called cc.


How To Use

To compress a directory:

cc c <directory path> <destination path>


To decompress a file

cc u <file path> <destination path>


Example:
I have a directory called 'secretStuff' with several files and directories inside it.

cc c secretStuff compressedSecretStuff
It would create a file called 'compressedSecretStuff' that I could then decompress if I wanted to.

Planned Features

- Encryption (Enter a password, and your files are encrypted before compression)
-ACTUAL compression (currently, the 'compressed' file is actually larger than the directory)
- UI (Maybe)
- ??? Leave your suggestions!

Bugs and Questions

If you find a bug, leave the error (If it had one) and a brief description of anything that you think is relevant
If you have any questions, feel free to ask

Okay so if theres like 5 directories inside a directorie, will it still work?
HPWebcamAble #10
Posted 01 March 2015 - 12:56 AM
Okay so if theres like 5 directories inside a directorie, will it still work?

Yep
Wojbie #11
Posted 01 March 2015 - 08:04 PM
If you want encryption api you can use mine :D/>
Its not hard to break but it is historically accurate!

Enigma API!
HPWebcamAble #12
Posted 01 March 2015 - 09:14 PM
If you want encryption api you can use mine :D/>
Its not hard to break but it is historically accurate!

Enigma API!

Wow I was actually thinking about trying to make the Enigma in CC. Looks like you saved me some work there :P/>

I'm not sure how I'll encrypt it. I won't be adding it right away, so I'll have some time to think about it.
TheOddByte #13
Posted 01 March 2015 - 09:25 PM
I've got a suggestion, compress files using Base64.
Bomb Bloke #14
Posted 02 March 2015 - 12:21 AM
Base64 is not a method of compression. In fact, it increases file sizes by a third, by taking every three bytes and representing them using four characters. This is great if you need to transmit data using a protocol that only supports ASCII, but quite useless otherwise.

I suppose I may as well point out that I've made an API that can do base64 conversions, and can also compress/decompress data:

http://www.computercraft.info/forums2/index.php?/topic/21801-package-pastebin-uploader-downloader/
Boom #15
Posted 02 March 2015 - 02:17 PM
Nice! This program is like a cc fork of winzip lol
Lupus590 #16
Posted 02 March 2015 - 03:42 PM
This would be great for project distribution (shameless plug: https://github.com/lupus590/Hive), would like to be able to have the resulting file extract itself before I use it though (as already suggested by awsumben13)

Nice idea, although I'd recommend adding self-extracting archives.
.
TheOddByte #17
Posted 02 March 2015 - 09:26 PM
I didn't know that, I thought it actually became smaller when using Base64, well I guess I learned something new today, thanks for that! :D/>
HPWebcamAble #18
Posted 03 March 2015 - 01:08 AM
This would be great for project distribution (shameless plug: https://github.com/lupus590/Hive), would like to be able to have the resulting file extract itself before I use it though (as already suggested by awsumben13)

Nice idea, although I'd recommend adding self-extracting archives.
.

Yep, I'll get on that soon