GithubHelp home page GithubHelp logo

compresssafe's Introduction

CompressSafe

CompressSafe is a command-line tool for compressing files using gzip, decompressing them, verifying their integrity, and cleaning up temporary decompressed files. It supports processing individual files as well as entire directories, while ignoring already compressed files.

Usage

Running on Windows

  1. Download compresssafe.exe
  2. Run in the commandline
compresssafe.exe -input <path>

Running on macOS/Linux

compresssafe -input <path>

Parameters

  • input : Specifies the input file or directory path to be processed.

Features

  • Compresses files using gzip.
  • Decompresses gzip-compressed files.
  • Verifies the integrity of decompressed files by comparing checksums.
  • Processes directories recursively.
  • Skips files that are already compressed.
  • Removes temporary decompressed files after processing.

Installation advanced

Requirements

  • Go 1.16 or later
  1. Clone the repository or download the source code.
  2. Navigate to the directory containing the source code.
  3. Build the executable for your target operating system.

Building for Windows

GOOS=windows GOARCH=amd64 go build -o compresssafe.exe compresssafe.go

How it Works

  1. Compression: The tool compresses each file using gzip and appends the .gz extension.
  2. Decompression: The tool decompresses the compressed file to a temporary directory named decompressed.
  3. Verification: The tool calculates and compares the SHA-256 checksum of the original file and the decompressed file to ensure they are identical.
  4. Cleanup: After processing all files, the tool removes the temporary decompressed directory.

compresssafe's People

Contributors

elena-krismer avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.