Transform your text files with ease using smart case conversions, number base transformations, and intelligent formatting!
Welcome to Go-Reloaded!
This command-line text processor is designed to make your life easier by automating tedious text transformations. Simply provide an input file, and watch as Go-Reloaded applies sophisticated transformations to produce beautifully formatted output. Whether you need case conversions, number base changes, or smart grammar corrections, we've got you covered!
- Case Conversions: Convert text to uppercase
(up), lowercase(low), or capitalize(cap) - Number Base Conversions:
- Binary to decimal
(bin) - Hexadecimal to decimal
(hex)
- Binary to decimal
- Batch Case Conversions: Apply case changes to multiple previous words
(up, n)- Convert the lastnwords to uppercase(low, n)- Convert the lastnwords to lowercase(cap, n)- Capitalize the lastnwords
- Grammar Correction: Automatically converts "a" to "an" before vowels and 'h'
- Punctuation Formatting: Proper spacing around punctuation marks
- Quote Handling: Intelligent single quote placement and formatting
- Space Normalization: Removes unnecessary spaces while preserving proper formatting
- Go 1.19 or higher
1️⃣ Clone the repository:
git clone <repository-url>
cd go-reloaded2️⃣ Initialize the Go module:
go mod tidy3️⃣ Build the application:
cd goReloadedMain
go build -o go-reloaded main.go./go-reloaded <input_file> <output_file>./go-reloaded sample.txt result.txtInput:
hello world (up)
GOODBYE WORLD (low)
welcome home (cap)
1010 (bin)
A1 (hex)
Output:
hello WORLD
GOODBYE world
welcome Home
10
161
Input:
This is so exciting (up, 2)
I was thinking about Betty (cap, 1)
Output:
This is SO EXCITING
I was thinking about Betty
Input:
There it was a amazing day
I need a hour to complete this
Output:
There it was an amazing day
I need an hour to complete this
go-reloaded/
├── goReloadedMain/
│ ├── main.go # Main application logic and text processing
│ ├── sample.txt # Sample input file
│ └── result.txt # Output file
├── storage/ # Storage utilities package
│ ├── binToDec.go # Binary to decimal conversion
│ ├── hexToDec.go # Hexadecimal to decimal conversion
│ ├── getTxt.go # File reading functionality
│ └── getSizeFile.go # File size utility
├── go.mod # Go module definition
├── go.sum # Module dependencies
└── README.md # This file
The application includes comprehensive error handling:
- File existence validation
- Number conversion error checking
- Graceful exit on invalid inputs
- Informative error messages in French
- golang.org/x/text v0.13.0 - Text processing utilities (indirect dependency)
- Standard library packages:
fmt,os,strconv,strings
We welcome contributions! Here's how you can help:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Add tests if applicable
- Submit a pull request
- Always check that your input and output files exist before running
- Use the debug mode by uncommenting print statements in
main.goto see intermediate steps - Test transformations on sample text before processing important files
- Combine multiple transformations for powerful text processing!
⭐ Star this repository if you found it helpful! ⭐
Made with ❤️ from 🇸🇳