Struct workspace_node_tools::git::commands::Git

source ·
pub struct Git;

Implementations§

source§

impl Git

source

pub fn fetch_all(cwd: Option<String>) -> Result<bool, Error>

Fetches all tracking information from origin.

source

pub fn fetch_all_tags(cwd: Option<String>) -> Result<bool, Error>

Pulls in all tags from origin and forces local to be updated @param {string} [cwd=monorepo root]

source

pub fn get_diverged_commit(refer: String, cwd: Option<String>) -> Option<String>

source

pub fn get_commits_since( cwd: Option<String>, since: Option<String>, relative: Option<String>, ) -> Vec<Commit>

Returns commits since a particular git SHA or tag. If the “since” parameter isn’t provided, all commits from the dawn of man are returned

source

pub fn get_remote_or_local_tags( cwd: Option<String>, local: Option<bool>, ) -> Vec<RemoteTags>

Grabs the full list of all tags available on upstream or local

source

pub fn get_last_known_publish_tag_info_for_package( package_info: PackageInfo, cwd: Option<String>, ) -> Option<PublishTagInfo>

source

pub fn get_last_known_publish_tag_info_for_all_packages( package_info: Vec<PackageInfo>, cwd: Option<String>, ) -> Vec<Option<PublishTagInfo>>

Grabs the last known publish tag info for all packages in the monorepo

source

pub fn git_all_files_changed_since_sha( sha: String, cwd: Option<String>, ) -> Vec<String>

Given a specific git sha, finds all files that have been modified since the sha and returns the absolute filepaths.

source

pub fn get_all_files_changed_since_tag_infos( package_info: Vec<PackageInfo>, tag_info: Vec<PublishTagInfo>, cwd: Option<String>, ) -> Vec<String>

Given an input of parsed git tag infos, returns all the files that have changed since any of these git tags have occured, with duplicates removed.

source

pub fn get_all_files_changed_since_branch( package_info: Vec<PackageInfo>, branch: String, cwd: Option<String>, ) -> Vec<String>

Given an input of the “main” branch name, returns all the files that have changed since the current branch was created

source

pub fn get_conventional_for_package( package_info: PackageInfo, no_fetch_all: Option<bool>, cwd: Option<String>, conventional_options: Option<ConventionalPackageOptions>, ) -> ConventionalPackage

source

pub fn git_commit( message: String, body: Option<String>, footer: Option<String>, cwd: Option<String>, ) -> Result<bool, Error>

source

pub fn git_push(cwd: Option<String>) -> Result<bool, Error>

source

pub fn git_tag( tag: String, message: Option<String>, cwd: Option<String>, ) -> Result<bool, Error>

source

pub fn git_current_sha(cwd: Option<String>) -> String

source

pub fn git_workdir_unclean(cwd: Option<String>) -> bool

Auto Trait Implementations§

§

impl Freeze for Git

§

impl RefUnwindSafe for Git

§

impl Send for Git

§

impl Sync for Git

§

impl Unpin for Git

§

impl UnwindSafe for Git

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

impl<T> Pointable for T

source§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<T> ErasedDestructor for T
where T: 'static,

source§

impl<T> MaybeSendSync for T