Gleef CLI provides a simple set of commands to manage your translation workflow. Each command is designed to handle a specific aspect of the localization process.

Available Commands

Command Reference

Core Commands

CommandPurposeWhen to Use
gleef initProject setupFirst time setting up Gleef in a project
gleef loginAuthenticationWhen setting up CLI or changing API keys
gleef translatePush translationsWhen you have new or modified translation keys
gleef pullSync translationsWhen you want to get latest translations from your team

Command Aliases

Some commands have convenient aliases:
CommandAliasDescription
gleef translategleef pushBoth commands perform the same function

Global Flags

All commands support these global flags:
FlagDescription
--helpShow help information for the command
--versionDisplay the CLI version

Getting Help

Get help for any command using the --help flag:
gleef --help              # General help
gleef init --help         # Help for init command
gleef translate --help    # Help for translate command
gleef pull --help         # Help for pull command
You can also use the dedicated help command:
gleef help                # General help
gleef help init           # Help for init command
gleef help translate      # Help for translate command

Command Workflow

Here’s the typical workflow using Gleef CLI commands:
1

Initial Setup

gleef login              # Authenticate once
gleef init               # Set up project configuration
2

Push New Content

gleef translate          # Send new keys for translation
3

Sync Updates

gleef pull               # Get latest translations
4

Ongoing Development

gleef translate          # Push changes
gleef pull               # Sync updates

Command Examples

Basic Usage

# Set up a new project
gleef init

# Push translations for AI processing
gleef translate

# Get latest translations
gleef pull

Advanced Usage

# Push only specific keys matching a pattern
gleef translate --match "button.*"

# Get all translations including new keys
gleef pull --all

# Check for new translations without updating
gleef pull --check

# Skip review process and publish immediately
gleef translate --skip-review

Error Handling

All commands provide clear error messages and exit codes:
  • Exit code 0: Command completed successfully
  • Exit code 1: Command failed with an error
Common error scenarios:
  • Authentication errors: Run gleef login to re-authenticate
  • Configuration errors: Check your .gleef/config.json file
  • Network errors: Verify your internet connection and API access
  • File errors: Ensure your locale files are properly formatted

Next Steps