Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/conaticus/click
/ functions
Functions
37 in github.com/conaticus/click
⨍
Functions
37
◇
Types & classes
16
↓ 1 callers
Method
execute
(&self)
src/commands/install.rs:66
↓ 1 callers
Method
exists
Checks if a package with a valid version matching with `semantic_version` is already in the cache and returns `true` if so, `false` if otherwise, as w
src/cache.rs:79
↓ 1 callers
Function
extract_tarball
(bytes: Bytes, dest: String)
src/util.rs:16
↓ 1 callers
Function
handle_args
(mut args: Args)
src/commands/command_handler.rs:17
↓ 1 callers
Method
parse
(&mut self, args: &mut Args)
src/commands/install.rs:53
Method
add_blocking
(f: F)
src/util.rs:46
Method
add_task
(future: T)
src/util.rs:32
Method
already_resolved
NOTE(conaticus): To save storage space, it might be an idea to check if the semantic version matches, rather than installing an whole new version, how
src/installer.rs:62
Method
append_version
Append a version to a specific parent version, this hashmap will be used to generate package lock files.
src/installer.rs:84
Method
block_until_done
()
src/util.rs:60
Method
create_modules_dir
Creates the node modules folder if it is not present.
src/installer.rs:196
Method
decrement_tasks
()
src/util.rs:70
Method
get_bytes
Download a file from any specified URL.
src/http.rs:13
Method
get_cached_versions
Returns a hashmap, each key is formatted as package@version and the value is a boolean of whether the package is the latest version or not.
src/cache.rs:41
Method
get_latest_version_in_cache
Checks if the latest version exists in the cache. This is checked by reading if the package lock has the latest property as true.
src/cache.rs:134
Method
get_version_data
Gets the version data taking in the full version rather than resolving it on its own.
src/installer.rs:38
Method
increment_tasks
()
src/util.rs:66
Method
install_dependencies
( parents_mux: Arc<Mutex<Vec<String>>>, context: InstallContext, dependencies: HashMap
src/installer.rs:149
Method
install_package
( context: InstallContext, package_info: PackageInfo, parents_mux: Arc<Mutex<Vec<Strin
src/installer.rs:105
Method
is_in_cache
(package: &String, version: &String)
src/cache.rs:124
Method
is_latest
Takes in a result of Versions::resolve_full_version()
src/versions.rs:132
Method
load_cached_version
Package string is formated as package@version
src/cache.rs:143
Function
main
()
src/main.rs:15
Method
new
(is_latest: bool)
src/types.rs:32
Method
package_data
This makes a request for all data for a package including all its versions. This method should be avoided where possible as its response size is much
src/http.rs:54
Method
parse_raw_package_details
(details: String)
src/versions.rs:24
Method
parse_semantic_package_details
(details: String)
src/versions.rs:44
Method
parse_semantic_version
(raw_version: &str)
src/versions.rs:38
Method
registry
Make a request to the NPM registry. This includes the recommended header to shorten the response size.
src/http.rs:26
Method
resolve_full_version
If a version comparator has the major, patch and minor available a string version will be returned with the resolved version. This version string can
src/versions.rs:59
Method
resolve_partial_version
Should only be executed if the version comparator is missing a minor or patch. This can be checked with resolve_full_version() which will return None
src/versions.rs:85
Method
sort
This might not be effective for versions that include a prerelease in the version (experimental, canary etc)
src/versions.rs:140
Method
stringify
(name: &String, version: &String)
src/versions.rs:127
Method
stringify_from_numbers
(major: u64, minor: u64, patch: u64)
src/versions.rs:144
Method
task_count
()
src/util.rs:74
Method
version_data
This makes a request for a specific version of a package. This method should always be preferred where possible as its response size is significantly
src/http.rs:43
Method
write_lockfiles
(dependency_map_mux: DependencyMapMutex)
src/commands/install.rs:29