Expand description
§Module
:: willbe
Utility to publish multi-crate and multi-workspace environments and maintain their consistency.
§Purpose
-
Multi-Workspace Consistency: In a project setup involving multiple workspaces with shared dependencies,
willbe
maintains consistency. It ensures all workspaces are updated with compatible dependency versions. -
Publishing Multi-Crate Projects: If your project structure includes multiple crates that need simultaneous publishing,
willbe
manages the process seamlessly. It ensures the crates are published in the right order while staying in version sync. -
Dependency Analysis:
willbe
can perform a thorough analysis of your project’s dependencies, providing a detailed highlight of inconsistencies or areas that need attention. -
Test Execution With Varied Configurations:
willbe
can execute tests with varying configurations, such as different combinations of crate features. This assists in ensuring comprehensive coverage of test scenarios. -
Generate Health Table: Quickly visualize important project metrics like build status for each crate, creating a single, easy-to-read table.
-
Automating CI/CD Workflow Generation: Automatically generate a series of CI/CD operations suitable for the task at hand to enhance productivity and improve the development process.
§To install
cargo install willbe
will .
§Try out from the repository
git clone https://github.com/Wandalen/wTools
cd wTools/module/move/willbe
cargo install --path .
will .
Modules§
- action
- Describes functions that can be called from an interface.
- attr
- Attributes analyzys and manipulation.
- attr_
prop - Attribute’s properties. Reuse them to define how to parse properties of an attribute.
- cargo
- Interaction module with the
cargo
utilities. - channel
- Rust toolchain channel: stable/nightly.
- code
- Source code.
- collection
- Function and structures to work with collections. Module containing all collection macros
- command
- Describes CLI commands.
- components
- Type-based assigning.
- container_
kind - Determine kind of a container.
- ct
- Compile-time tools.
- dependency
- Dependency of a package.
- derive
- Macro helpers around derive macro and structure
syn::DeriveInput
. - diag
- Macro helpers.
- diff
- Compare two crate archives and create a difference report.
- entity
- Entities of which spaces consists of.
- equation
- Attributes analyzys and manipulation.
- error
- Errors handling.
Alias for
std::error::BasicError
. - exposed
- Exposed namespace of the module.
- features
- Operation with features
- files
- Paths and files.
- generic_
args - This module provides utilities to handle and manipulate generic arguments using the
syn
crate. It includes traits and functions for transforming, merging, and managing generic parameters within procedural macros, enabling seamless syntactic analysis and code generation. - generic_
params - Functions and structures to handle and manipulate generic parameters using the
syn
crate. It’s designed to support macro-driven code generation by simplifying, merging, extracting, and decomposingsyn::Generics
. - git
- Git.
- graph
- Tools for working with dependencies graph.
- http
- Http requests.
- item
- This module provides various utilities and namespaces for working with
syn::Item
, specifically focusing on ensuring syntactical correctness and managing different visibility levels within the code. It includes functions to manipulate the structure of items, handle different kinds of fields, and provide a structured approach to organizing the codebase into different access levels. - item_
struct - Parse structures, like
struct { a : i32 }
. - iter
- Iterating things.
- kw
- Keywords
- macros
- Work with paths.
- manifest
- To manipulate manifest data.
- name
- Tait to getn name of an Item.
- optimization
- Rust build optimization: debug/release
- orphan
- Orphan namespace of the module.
- own
- Own namespace of the module.
- package
- Offers capabilities for package management, facilitating the handling and organization of packages.
- package_
md_ extension - Md’s extension for workspace.
- packages
- Provides a set of functionalities for handling and manipulating packages.
- packed_
crate - Handles operations related to packed Rust crates
- path
- Work with paths.
- phantom
- Responsible for generating marker
PhantomData
fields to avoid the rule requiring the usage of all generic parameters in a struct. This is often necessary to ensure that Rust’s type system correctly tracks the ownership and lifetimes of these parameters without needing them to be explicitly used in the struct’s fields. - prelude
- Prelude to use essentials:
use my_module::prelude::*
. - proc_
macro2 - github crates-io docs-rs
- progress_
bar - Progress bar staff.
- publish
- Publish.
- punctuated
- Structures and functions for handling
syn::punctuated::Punctuated
collections. - quantifier
- Quantifiers like Pair and Many.
- query
- The parse function parses an input string into a HashMap where the keys are String and the values are of type Value.
- quote
- github crates-io docs-rs
- repository
- Repository tools.
- struct_
like - Parse structures, like
struct { a : i32 }
. - syn
- github crates-io docs-rs
- table
- Facade for
preatytable
crate. - template
- Traits and structs for templates.
- test
- Operations with tests
- thiserror
- Errors handling. github crates-io docs-rs
- tokens
- Attributes analyzys and manipulation.
- tool
- Genera-purpose tools which might be moved out one day.
- tree
- Tools for printing a tree
- typ
- Advanced syntax elements.
- typed
- Typed parsing.
- url
- Tools for parsing and extracting information from url.
- version
- Provides an opportunity to work with versions.
- workspace
- It features the ability to interact with workspaces, manage their participants, and other functionalities.
- workspace_
graph - Workspace’ graph.
- workspace_
md_ extension - Md’s extension for workspace.
- workspace_
package - Packages of workspace.
Macros§
- Token
- A type-macro that expands to the name of the Rust type representation of a given token.
- bmap
- Function and structures to work with collections.
Creates a
BTreeMap
from a list of key-value pairs. - braced
- Parse a set of curly braces and expose their content to subsequent parsers.
- bracketed
- Parse a set of square brackets and expose their content to subsequent parsers.
- bset
- Function and structures to work with collections.
Creates a
BTreeSet
from a list of elements. - code_
diagnostics_ str - Macro for diagnostics purpose to diagnose source code behind it and export it into a string.
- code_
print - Macro for diagnostics purpose to print both syntax tree and source code behind it without syntax tree.
- code_
to_ str - Macro to export source code behind a syntax tree into a string.
- custom_
keyword - Define a type that supports parsing and printing a given identifier as if it were a keyword.
- custom_
punctuation - Define a type that supports parsing and printing a multi-character symbol as if it were a punctuation token.
- debug_
assert_ id - Errors handling.
- debug_
assert_ identical - Errors handling.
Macro asserts that two expressions are identical to each other. Unlike
std::assert_eq
it is removed from a release build. Alias ofdebug_assert_id
. - debug_
assert_ ni - Errors handling.
Macro asserts that two expressions are not identical to each other. Unlike
std::assert_eq
it is removed from a release build. - debug_
assert_ not_ identical - Errors handling.
Macro asserts that two expressions are not identical to each other. Unlike
std::assert_eq
it is removed from a release build. - deque
- Function and structures to work with collections.
Creates a
VecDeque
from a list of elements. - dlist
- Function and structures to work with collections.
Creates a
Vec
from a list of elements. - format_
ident - Formatting macro for constructing
Ident
s. - hmap
- Function and structures to work with collections.
Creates a
HashMap
from a list of key-value pairs. - hset
- Function and structures to work with collections.
Creates a
HashSet
from a list of elements. - into_
bmap - Function and structures to work with collections.
Creates a
BTreeMap
from a list of key-value pairs. - into_
bset - Function and structures to work with collections.
Creates a
BTreeSet
from a list of elements. - into_
dlist - Function and structures to work with collections.
Creates a
Vec
from a list of elements. - into_
hmap - Function and structures to work with collections.
Creates a
HashMap
from a list of key-value pairs. - into_
hset - Function and structures to work with collections.
Creates a
HashSet
from a list of elements. - into_
llist - Function and structures to work with collections.
Creates a
LinkedList
from a llist of elements. - into_
vec - Function and structures to work with collections.
Creates a
Vec
from a list of elements. - into_
vecd - Function and structures to work with collections.
Creates a
VecDeque
from a list of elements. - llist
- Function and structures to work with collections.
Creates a
LinkedList
from a llist of elements. - mod_
interface - Protocol of modularity unifying interface of a module and introducing layers.
- parenthesized
- Parse a set of parentheses and expose their content to subsequent parsers.
- parse_
macro_ input - Parse the input TokenStream of a macro, triggering a compile error if the tokens fail to parse.
- parse_
qt - Quasi-quotation macro that accepts input like the
quote!
macro but uses type inference to figure out a return type for those tokens. - parse_
qt_ spanned - This macro is
parse_quote!
+quote_spanned!
. - parse_
quote - Quasi-quotation macro that accepts input like the
quote!
macro but uses type inference to figure out a return type for those tokens. - parse_
quote_ spanned - This macro is
parse_quote!
+quote_spanned!
. - qt
- The whole point.
- quote
- The whole point.
- quote_
spanned - Same as
quote!
, but applies a given span to all tokens originating within the macro invocation. - return_
syn_ err - Macro to generate syn error either with span of a syntax tree element or with default one
proc_macro2::Span::call_site()
. - syn_err
- Macro to generate syn error either with span of a syntax tree element or with default one
proc_macro2::Span::call_site()
. - tree_
diagnostics_ str - Macro for diagnostics purpose to export both syntax tree and source code behind it into a string.
- tree_
print - Macro for diagnostics purpose to print both syntax tree and source code behind it with syntax tree.
Structs§
- Absolute
Path - A new type representing an absolute path.
- Attribute
Property Boolean - A generic boolean attribute property.
Defaults to
false
. - Attribute
Property Boolean Marker - Default marker for
AttributePropertyBoolean
. Used if no marker is defined as parameter. - Attribute
Property Optional Boolean - A generic optional boolean attribute property:
Option< bool >
. Defaults tofalse
. - Attribute
Property Optional Boolean Marker - Default marker for
AttributePropertyOptionalSingletone
. Used if no marker is defined as parameter. - Attribute
Property Optional Singletone - A generic attribute property for switching on/off.
Has 3 states:
None
,Some( true )
,Some( false )
. Defaults toNone
. - Attribute
Property Optional Singletone Marker - Default marker for
AttributePropertyOptionalSingletone
. Used if no marker is defined as parameter. - Attribute
Property Optional Syn - Property of an attribute which simply wraps one of the standard
syn
types and keeps it optional. - Attribute
Property Optional SynMarker - Default marker for
AttributePropertyOptionalSyn
. Used if no marker is defined as parameter. - Attribute
Property Singletone - A generic boolean attribute property which consists of only keyword.
This property can have two states:
true
, orfalse
. Defaults tofalse
. - Attribute
Property Singletone Marker - Default marker for
AttributePropertySingletone
. Used if no marker is defined as parameter. - Attribute
Property Syn - Property of an attribute which simply wraps one of the standard
syn
types. - Attribute
Property SynMarker - Default marker for
AttributePropertySyn
. Used if no marker is defined as parameter. - Attributes
Inner - Attribute which is inner.
- Attributes
Outer - Represents a collection of outer attributes.
- BTree
Map - Function and structures to work with collections. An ordered map based on a B-Tree.
- BTree
MapDefinition - Represents the formation definition for a hash map-like collection within the former framework.
- BTree
MapDefinition Types - Holds the generic parameters for the
BTreeMapDefinition
. - BTree
Set - Function and structures to work with collections. An ordered set based on a B-Tree.
- BTree
SetDefinition - Represents the formation definition for a binary tree set-like collection within the former framework.
- BTree
SetDefinition Types - Holds the generic parameters for the
BTreeSetDefinition
. - Binary
Heap - Function and structures to work with collections. A priority queue implemented with a binary heap.
- Binary
Heap Definition - Represents the formation definition for a binary heap-like collection within the former framework.
- Binary
Heap Definition Types - Holds the generic parameters for the
BinaryHeapDefinition
. - Bmap
- Function and structures to work with collections. An ordered map based on a B-Tree.
- Bset
- Function and structures to work with collections. An ordered set based on a B-Tree.
- Canonical
Path - Caninical path.
- Collection
Former - A builder structure for constructing collections with a fluent and flexible interface.
- Crate
Dir - Path to crate directory
- Current
Path - Symbolize current path.
- Dependency
Ref - A dependency of the main crate
- Deque
- Function and structures to work with collections. A double-ended queue implemented with a growable ring buffer.
- Dlist
- Function and structures to work with collections.
A contiguous growable array type, written as
Vec<T>
, short for ‘vector’. - Either
DirOr File - Wrapper over
data_type::Either< CrateDir, ManifestFile >
with util methods. - Equation
- Represents an equation parsed from a procedural macro input.
- Forming
EndClosure - A wrapper around a closure to be used as a
FormingEnd
. - HashMap
- Function and structures to work with collections. A hash map implemented with quadratic probing and SIMD lookup.
- Hash
MapDefinition - Represents the formation definition for a hash map-like collection within the former framework.
- Hash
MapDefinition Types - Holds the generic parameters for the
HashMapDefinition
. - HashSet
- Function and structures to work with collections.
A hash set implemented as a
HashMap
where the value is()
. - Hash
SetDefinition - Represents the formation definition for a hash set-like collection within the former framework.
- Hash
SetDefinition Types - Holds the generic parameters for the
HashSetDefinition
. - Hmap
- Function and structures to work with collections. A hash map implemented with quadratic probing and SIMD lookup.
- Hset
- Function and structures to work with collections.
A hash set implemented as a
HashMap
where the value is()
. - Linked
List - Function and structures to work with collections. A doubly-linked list with owned nodes.
- Linked
List Definition - Represents the formation definition for a list-like collection within the former framework.
- Linked
List Definition Types - Holds the generic parameters for the
LinkedListDefinition
. - Llist
- Function and structures to work with collections. A doubly-linked list with owned nodes.
- Manifest
- Hold manifest data.
- Manifest
File - Path to crate directory
- Many
- Parse as much elements as possible.
- Map
- Function and structures to work with collections. A hash map implemented with quadratic probing and SIMD lookup.
- Native
Path - Caninical path.
- NoEnd
- A placeholder
FormingEnd
used when no end operation is required or applicable. - Pair
- Pair of two elements of parsing.
- Return
Preformed - A
FormingEnd
implementation that directly returns the formed collection as the final product of the forming process. - Return
Storage - A
FormingEnd
implementation that returns the storage itself as the formed entity, disregarding any contextual data. - Set
- Function and structures to work with collections.
A hash set implemented as a
HashMap
where the value is()
. - Source
File - Path to a source file
- Tokens
Tokens
is a wrapper aroundproc_macro2::TokenStream
. It is designed to facilitate the parsing and manipulation of token streams within procedural macros.- Vec
- Function and structures to work with collections.
A contiguous growable array type, written as
Vec<T>
, short for ‘vector’. - VecDeque
- Function and structures to work with collections. A double-ended queue implemented with a growable ring buffer.
- VecDeque
Definition - Represents the formation definition for a vector deque-like collection within the former framework.
- VecDeque
Definition Types - Holds the generic parameters for the
VecDequeDefinition
. - Vector
Definition - Represents the formation definition for a vector-like collection within the former framework.
- Vector
Definition Types - Holds the generic parameters for the
VectorDefinition
. - Version
- Version entity.
Wrapper for a
SemVer
structure - Workspace
- Stores information about the current workspace.
- Workspace
Package Ref - Facade for
cargo_metadata::Package
Enums§
- Dependency
Kind - Dependencies can come in three kinds
- Diff
- A type returned by the
diff_with
function. - Either
- The enum
Either
with variantsLeft
andRight
is a general purpose sum type with two cases. - Either
OrBoth - Value that either holds a single A or B, or both.
- Fold
While - An enum used for controlling the execution of
fold_while
. - MinMax
Result MinMaxResult
is an enum returned byminmax
.- Package
- Represents different types of packages in a Cargo workspace.
- Path
Error PathError
enum represents errors when creating aCrateDir
object.- Position
- The first component of the value yielded by
WithPosition
. Indicates the position of this element in the iterator results. - Workspace
Init Error - Represents errors related to workspace operations.
Traits§
- AsCode
- A trait for converting an object to its code representation.
- AsMuch
AsPossible NoDelimiter - Marker saying how to parse several elements of such type in a row.
- Assign
- Provides a generic interface for setting a component of a certain type on an object.
- Assign
With Type - The
AssignWithType
trait provides a mechanism to set a component on an object, utilizing the type information explicitly. This trait extends the functionality ofAssign
by allowing implementers to specify the component’s type at the method call site, enhancing expressiveness in code that manipulates object states. - Attribute
Component - Trait for components of a structure aggregating attributes that can be constructed from a meta attribute.
- Attribute
Property Component - Trait for properties of an attribute component that can be identified by a keyword.
- BTree
MapExt - Provides an extension method for hash maps to facilitate the use of the builder pattern.
- BTree
SetExt - Provides an extension method for binary tree sets to facilitate the use of the builder pattern.
- Binary
Heap Ext - Provides an extension method for binary heaps to facilitate the use of the builder pattern.
- Code
Items - A trait for retrieving an iterator over items of a source file.
- Collection
- Represents a collection by defining the types of entries and values it handles.
- Collection
Add - Provides functionality to add individual entries to a collection.
- Collection
Assign - Defines the capability to replace all entries in a collection with a new set of entries.
- Collection
ValTo Entry - Provides a mechanism for transforming a value back into a collection-specific entry format.
- Entity
ToDefinition - Maps a type of entity to its corresponding former definition. This trait provides a linkage between the entity and its definition, allowing the formation logic to understand what definition to apply during the formation process.
- Entity
ToDefinition Types - Provides a mapping between a type of entity and its associated formation type definitions.
- Entity
ToFormer - Maps a type of entity to its corresponding former. This trait binds an entity type to a specific former, facilitating the use of custom formers in complex formation scenarios.
- Entity
ToStorage - Maps a type of entity to its storage type. This trait defines what storage structure is used to hold the interim state of an entity during its formation.
- Entries
- A trait that defines a method for retrieving an iterator over entries.
- Entry
ToVal - Facilitates the conversion of collection entries to their corresponding value representations.
- ErrWith
- Errors handling. This trait allows adding extra context or information to an error, creating a tuple of the additional context and the original error. This is particularly useful for error handling when you want to include more details in the error without losing the original error value.
- Former
Begin - A trait for initiating a structured subforming process with contextual and intermediary storage linkage.
- Former
Definition - Expands on
FormerDefinitionTypes
by incorporating an ending mechanism for the formation process. This trait connects the formation types with a specific endpoint, defining how the formation process concludes, including any necessary transformations or validations. - Former
Definition Types - Defines the fundamental components involved in the formation of an entity. This trait specifies the types of storage, the formed entity, and the context used during the formation process.
- Former
Mutator - Provides a mechanism for mutating the context and storage just before the forming process is completed.
- Forming
End - Defines a handler for the end of a subforming process, enabling the return of the original context.
- Hash
MapExt - Provides an extension method for hash maps to facilitate the use of the builder pattern.
- Hash
SetExt - Provides an extension method for
HashSet
to facilitate the use of the builder pattern. - Into
Interval - Convert it into canonical interval.
- IterExt
- Extension of iterator.
- Iter
Trait - Trait that encapsulates a clonable iterator with specific characteristics, tailored for use with the
syn
crate. - Iterable
Interval - Interval adapter. Interface to interval-like structures.
- Itertools
- An
Iterator
blanket implementation that provides extra adaptors and methods. - Linked
List Ext - Provides an extension method for lists to facilitate the use of the builder pattern.
- Name
- Trait to get name of an syntax element.
- NonIterable
Interval - Interval adapter. Interface to interval-like structures.
- Option
Ext - Extension trait to provide a method for setting a component on an
Option<Self>
if theOption
is currentlyNone
. If theOption
isSome
, the method will delegate to theAssign
trait’sassign
method. - Path
Joined - A trait for joining path components into a
PathBuf
. - Peeking
Next - An iterator that allows peeking at an element before deciding to accept it.
- Sources
- A trait that defines a method for retrieving an iterator over source files.
- Spanned
- A trait that can provide the
Span
of the complete contents of a syntax tree node. - Storage
- Defines the storage interface for entities being constructed using a forming pattern.
- Storage
Preform - Provides a mechanism to finalize the forming process by converting storage into its final formed state.
- Transitive
TryFrom - A trait to perform a transitive
try_from
conversion. - Transitive
TryInto - A trait to perform a transitive
try_into
conversion. - ValTo
Entry - Facilitates the conversion of values back into entries for specific collection types.
- VecDeque
Ext - Provides an extension method for vector deques to facilitate the use of the builder pattern.
- VecExt
- Provides an extension method for vectors to facilitate the use of the builder pattern.
- _Iter
Trait - Trait that encapsulates an iterator with specific characteristics and implemetning
CloneDyn
.
Functions§
- cicd_
renew - List packages.
- indentation
- Adds indentation and optional prefix/postfix to each line of the given string.
- is
- Check is string a keyword.
- report_
format - Formats a debugging report for code transformation processes, detailing both the original and generated code for easy comparison and review.
- report_
print - Prints a debugging report for a pair of token streams to the standard output.
- run
- Takes the command line arguments and perform associated function(s). If no arguments are provided, the function identifies this as an ambiguous state and prompts the user with a help message, suggesting possible commands they might want to execute. It then terminates the program with an exit code of 1 to indicate an error due to the lack of input.
- test
- run tests in specified crate run tests in specified crate
- workspace_
renew - List packages.
Type Aliases§
- BTree
MapFormer - Provides a streamlined builder interface for constructing hash map-like collections.
- BTree
SetFormer - Provides a streamlined builder interface for constructing binary tree set-like collections.
- Binary
Heap Former - Provides a streamlined builder interface for constructing binary heap-like collections.
- Boxed
Iter - Type alias for boxed
_IterTrait
trait objects. - Hash
MapFormer - Provides a streamlined builder interface for constructing hash map-like collections.
- Hash
SetFormer - Provides a concise alias for
CollectionFormer
configured specifically forHashSet
-like collections. - Linked
List Former - Provides a streamlined builder interface for constructing list-like collections.
- Parse
Stream - Input to a Syn parser function.
- Result
With Report - Errors handling.
A type alias for a
Result
that contains an error which is a tuple of a report and an original error. - VecDeque
Former - Provides a streamlined builder interface for constructing vector deque-like collections.
- Vector
Former - Provides a streamlined builder interface for constructing vector-like collections.