Expand description
hyperlane-cli
A command-line tool for Hyperlane framework.
Re-exports§
pub use log;
Macros§
- output_
macro - Macro for outputting colored text to the terminal.
- println_
error - Prints an error message with red background and white text.
- println_
success - Prints a success message with green background and white text.
- println_
warning - Prints a warning message with yellow background and white text.
Structs§
- Args
- Parsed command line arguments
- Color
Contrast - Provides utilities for calculating and ensuring color contrast ratios.
- Color
Output - Represents a colored text output with formatting options.
- Color
Output Builder - Builder pattern for constructing ColorOutput configurations.
- Color
Output List - Represents a list of ColorOutput configurations for sequential execution.
- Color
Output List Builder - Builder pattern for constructing ColorOutputList configurations.
- Logger
- Custom logger implementation for the hyperlane-cli.
- NewProject
Config - Configuration for creating a new project
- Package
- Package information in monorepo
- Publish
Result - Publish result for a single package
- Task
- Represents a collection of text tasks to be executed sequentially.
- Template
Config - Configuration for template generation
- Text
- Configurable text display with color, background and style options.
- Version
- Parsed version components following semantic versioning
Enums§
- Bump
Version Type - Types of version bumps
- Color
- Predefined color constants for easy text formatting.
- Color
Type - Represents different types of colors that can be used for text formatting.
- Command
Type - Available commands
- Display
Type - Specifies whether color applies to text or background.
- Model
SubType - Model subtypes for organizing data structures
- NewError
- Errors that can occur during project creation
- Publish
Error - Error types for publish operation
- Template
Error - Errors that can occur during template generation
- Template
Type - Types of template components that can be generated
Constants§
- COMMON_
YEAR - Common Year
- DAYS
- Days
- LEAP_
YEAR - Leap Year
- MONTHS
- Months
Statics§
- DERIVE_
REGEX - Regex pattern to match derive attribute
Traits§
- Color
Display - Trait for converting colors to their ANSI escape sequences.
Functions§
- __
println_ text - calculate_
time - Calculates the current year, month, day, hour, minute, second, millisecond and microsecond.
- color256_
bg_ color - Generates color code for background colors in 256 colors.
- color256_
fg_ color - Generates color code for foreground colors in 256 colors.
- compute_
date - Computes the year, month, and day from days since Unix epoch (1970-01-01).
- date
- Gets the current day, without the time.
- day
- Gets the current day.
- execute_
bump - Read and update version in Cargo.toml
- execute_
fmt - Execute fmt command
- execute_
new - Execute new command to create a project from template
- execute_
publish - Execute publish command for all packages in workspace
- execute_
template - Execute template generation
- execute_
watch - Execute watch command using cargo-watch
- format_
path - Format code at specific path
- from_
env_ var - Gets the time zone offset from the system environment variable.
- gmt
- Gets the current date and time in GMT format.
- hour
- Gets the current hour.
- is_
leap_ year - Determines if a year is a leap year.
- micros
- Gets the current timestamp in microseconds.
- millis
- Gets the current timestamp in milliseconds.
- minute
- Gets the current minute.
- month
- Gets the current month.
- output
- Executes the output operation with the given formatting.
- output_
list - Executes a sequence of output operations.
- parse_
args - Parse command line arguments
- print_
help - Print help message
- print_
version - Print version
- rgb_
bg_ color - Generates color code for true color background colors.
- rgb_
fg_ color - Generates color code for true color foreground colors.
- second
- Gets the current second.
- time
- Gets the current time, including the date and time.
- time_
micros - Gets the current time with microseconds, including the date and time.
- time_
millis - Gets the current time with milliseconds, including the date and time.
- timestamp
- Gets the current timestamp in seconds since Unix epoch.
- timestamp_
micros - Gets the current timestamp in microseconds since Unix epoch.
- timestamp_
millis - Gets the current timestamp in milliseconds since Unix epoch.
- year
- Gets the current year.