A command-line interface for interacting with the 0x45.st file and URL sharing service.
- 📤 Upload files and get shareable links
- 🔗 Shorten URLs
- 📋 List your uploaded files and shortened URLs
- 🗑️ Delete uploaded content
- ⚙️ Configurable settings
- 🔑 API key management
Requires Go 1.18 or later.
go install github.com/watzon/0x45-cli/cmd/0x45@latest
The command will be installed as 0x45
in your $GOPATH/bin
directory.
Alternatively, you can clone and build from source:
git clone https://github.com/watzon/0x45-cli.git
cd 0x45-cli
go build -o $GOPATH/bin/0x45 ./cmd/0x45
Before using the CLI, you'll need to configure it with your 0x45.st API key:
0x45 config set api_key YOUR_API_KEY
You can also configure the API URL if you're using a self-hosted instance:
0x45 config set api_url https://your-instance.com
0x45 upload path/to/file.txt
Options:
--private
: Make the upload private--expires
: Set expiration time (e.g., "24h", "7d", "1month")
0x45 shorten https://very-long-url.com
Options:
--private
: Make the shortened URL private--expires
: Set expiration time
List all your uploads:
0x45 list pastes
List shortened URLs:
0x45 list urls
Options:
--page
: Page number for pagination--limit
: Number of items per page
0x45 delete CONTENT_ID
Get a config value:
0x45 config get KEY
Set a config value:
0x45 config set KEY VALUE
To get an API key, visit 0x45.st and request one using:
0x45 key request --name "You Name" --email "your@email.com"
- Go 1.16 or later
- golangci-lint for linting
go test -v ./...
golangci-lint run
MIT License - see LICENSE for details.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -am 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request