diff --git a/CHANGELOG.md b/CHANGELOG.md index e1d7464..a250b2e 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ ## CHANGELOG +### v0.14.13 (2023-10-07) + +* Remove shippable + ### v0.14.12 (2023-10-04) * Improve azure pipelines support diff --git a/Cargo.toml b/Cargo.toml index 32122f5..816bbad 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ci_info" -version = "0.14.12" +version = "0.14.13" authors = ["Sagie Gur-Ari "] description = "Provides current CI environment information." license = "Apache-2.0" diff --git a/README.md b/README.md index 446ed3c..ba3d055 100644 --- a/README.md +++ b/README.md @@ -91,7 +91,7 @@ In order to use this library, just add it as a dependency: ```ini [dependencies] -ci_info = "^0.14.12" +ci_info = "^0.14.13" ``` There is optional `serde` support that can be enabled via the `serde-1` feature: diff --git a/docs/api/ci_info/index.html b/docs/api/ci_info/index.html index 629e98e..dd6d2ef 100644 --- a/docs/api/ci_info/index.html +++ b/docs/api/ci_info/index.html @@ -1,4 +1,4 @@ -ci_info - Rust

Crate ci_info

source ·
Expand description

ci_info

+ci_info - Rust

Crate ci_info

source ·
Expand description

ci_info

Provides current CI environment information.

This library main goal is to provide development/build tools such as cargo-make the needed information on the current CI environment.
The code is based on the ci-info npm module.

diff --git a/docs/api/ci_info/types/enum.Vendor.html b/docs/api/ci_info/types/enum.Vendor.html index c61efed..b99ce73 100644 --- a/docs/api/ci_info/types/enum.Vendor.html +++ b/docs/api/ci_info/types/enum.Vendor.html @@ -1,5 +1,5 @@ -Vendor in ci_info::types - Rust

Enum ci_info::types::Vendor

source ·
#[non_exhaustive]
pub enum Vendor { -
Show 51 variants Agola, +Vendor in ci_info::types - Rust

Enum ci_info::types::Vendor

source ·
#[non_exhaustive]
pub enum Vendor { +
Show 50 variants Agola, AppCenter, AppCircle, AppVeyor, @@ -37,7 +37,6 @@ SailCI, Screwdriver, Semaphore, - Shippable, SolanoCI, SourceHut, StriderCD, @@ -89,7 +88,6 @@
§

SailCI

CI vendor

§

Screwdriver

CI vendor

§

Semaphore

CI vendor

-
§

Shippable

CI vendor

§

SolanoCI

CI vendor

§

SourceHut

CI vendor

§

StriderCD

CI vendor

diff --git a/docs/api/ci_info/types/index.html b/docs/api/ci_info/types/index.html index f8e8147..01b68cb 100644 --- a/docs/api/ci_info/types/index.html +++ b/docs/api/ci_info/types/index.html @@ -1,3 +1,3 @@ -ci_info::types - Rust

Module ci_info::types

source ·
Expand description

types

+ci_info::types - Rust

Module ci_info::types

source ·
Expand description

types

Defines the various types and aliases.

Structs

Enums

\ No newline at end of file diff --git a/docs/api/ci_info/types/struct.CiInfo.html b/docs/api/ci_info/types/struct.CiInfo.html index f4399aa..aa8d9ae 100644 --- a/docs/api/ci_info/types/struct.CiInfo.html +++ b/docs/api/ci_info/types/struct.CiInfo.html @@ -1,4 +1,4 @@ -CiInfo in ci_info::types - Rust

Struct ci_info::types::CiInfo

source ·
pub struct CiInfo {
+CiInfo in ci_info::types - Rust

Struct ci_info::types::CiInfo

source ·
pub struct CiInfo {
     pub vendor: Option<Vendor>,
     pub name: Option<String>,
     pub ci: bool,
@@ -10,10 +10,10 @@
 
§ci: bool

True if CI environment

§pr: Option<bool>

True if currently running a PR build, None if unknown

§branch_name: Option<String>

The branch name for the given build

-

Implementations§

source§

impl CiInfo

source

pub fn new() -> CiInfo

Returns new instance

-

Trait Implementations§

source§

impl Clone for CiInfo

source§

fn clone(&self) -> CiInfo

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CiInfo

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for CiInfo

source§

fn default() -> CiInfo

Returns the “default value” for a type. Read more
source§

impl PartialEq<CiInfo> for CiInfo

source§

fn eq(&self, other: &CiInfo) -> bool

This method tests for self and other values to be equal, and is used +

Implementations§

source§

impl CiInfo

source

pub fn new() -> CiInfo

Returns new instance

+

Trait Implementations§

source§

impl Clone for CiInfo

source§

fn clone(&self) -> CiInfo

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CiInfo

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for CiInfo

source§

fn default() -> CiInfo

Returns the “default value” for a type. Read more
source§

impl PartialEq<CiInfo> for CiInfo

source§

fn eq(&self, other: &CiInfo) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl StructuralPartialEq for CiInfo

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +sufficient, and should not be overridden without very good reason.

source§

impl StructuralPartialEq for CiInfo

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere 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.

diff --git a/docs/api/implementors/core/marker/trait.StructuralPartialEq.js b/docs/api/implementors/core/marker/trait.StructuralPartialEq.js index caf66aa..7c7011e 100644 --- a/docs/api/implementors/core/marker/trait.StructuralPartialEq.js +++ b/docs/api/implementors/core/marker/trait.StructuralPartialEq.js @@ -1,3 +1,3 @@ (function() {var implementors = { -"ci_info":[["impl StructuralPartialEq for CiInfo"],["impl StructuralPartialEq for Vendor"]] +"ci_info":[["impl StructuralPartialEq for Vendor"],["impl StructuralPartialEq for CiInfo"]] };if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/api/search-index.js b/docs/api/search-index.js index 66aab05..d090668 100644 --- a/docs/api/search-index.js +++ b/docs/api/search-index.js @@ -1,5 +1,5 @@ var searchIndex = JSON.parse('{\ -"ci_info":{"doc":"ci_info","t":"FFFANNNNNNNNNNNDNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNENNNNLLLLMMLLLLLLLLLLLLLMLMLLLLLLLLM","n":["get","is_ci","mock_ci","types","AWSCodeBuild","Agola","AppCenter","AppCircle","AppVeyor","AzurePipelines","Bamboo","BitbucketPipelines","Bitrise","Buddy","Buildkite","CiInfo","CircleCI","CirrusCI","Codefresh","Codemagic","Codeship","DSARI","Drone","FlowCI","Gerrit","GitHubActions","GitLabCI","GoCD","GoogleCloudBuild","HarnessCI","Heroku","Hudson","Jenkins","JenkinsX","LayerCI","MagnumCI","NetlifyCI","Nevercode","Prow","Render","SailCI","Screwdriver","Semaphore","Shippable","SolanoCI","SourceHut","StriderCD","TaskCluster","TeamCity","TravisCI","Unknown","Vela","Vendor","Vercel","WoodpeckerCI","XcodeCloud","XcodeServer","borrow","borrow","borrow_mut","borrow_mut","branch_name","ci","clone","clone","clone_into","clone_into","default","eq","eq","fmt","fmt","from","from","into","into","name","new","pr","to_owned","to_owned","try_from","try_from","try_into","try_into","type_id","type_id","vendor"],"q":[[0,"ci_info"],[4,"ci_info::types"]],"d":["Loads and returns the CI info of the current environment.","Returns true if a CI environment is detected.","This function will modify the current environment …","types","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI info","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","Supported vendors enum","CI vendor","CI vendor","CI vendor","CI vendor","","","","","The branch name for the given build","True if CI environment","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","vendor name","Returns new instance","True if currently running a PR build, None if unknown","","","","","","","","","The CI vendor"],"i":[0,0,0,0,3,3,3,3,3,3,3,3,3,3,3,0,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,0,3,3,3,3,3,1,3,1,1,1,3,1,3,1,1,3,1,3,1,3,1,3,1,1,1,1,3,1,3,1,3,1,3,1,1],"f":[[[],1],[[],2],[1],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[]],[[]],[[]],[[]],0,0,[3,3],[1,1],[[]],[[]],[[],1],[[3,3],2],[[1,1],2],[[3,4],5],[[1,4],5],[[]],[[]],[[]],[[]],0,[[],1],0,[[]],[[]],[[],6],[[],6],[[],6],[[],6],[[],7],[[],7],0],"c":[],"p":[[3,"CiInfo"],[15,"bool"],[4,"Vendor"],[3,"Formatter"],[6,"Result"],[4,"Result"],[3,"TypeId"]]}\ +"ci_info":{"doc":"ci_info","t":"FFFANNNNNNNNNNNDNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNENNNNLLLLMMLLLLLLLLLLLLLMLMLLLLLLLLM","n":["get","is_ci","mock_ci","types","AWSCodeBuild","Agola","AppCenter","AppCircle","AppVeyor","AzurePipelines","Bamboo","BitbucketPipelines","Bitrise","Buddy","Buildkite","CiInfo","CircleCI","CirrusCI","Codefresh","Codemagic","Codeship","DSARI","Drone","FlowCI","Gerrit","GitHubActions","GitLabCI","GoCD","GoogleCloudBuild","HarnessCI","Heroku","Hudson","Jenkins","JenkinsX","LayerCI","MagnumCI","NetlifyCI","Nevercode","Prow","Render","SailCI","Screwdriver","Semaphore","SolanoCI","SourceHut","StriderCD","TaskCluster","TeamCity","TravisCI","Unknown","Vela","Vendor","Vercel","WoodpeckerCI","XcodeCloud","XcodeServer","borrow","borrow","borrow_mut","borrow_mut","branch_name","ci","clone","clone","clone_into","clone_into","default","eq","eq","fmt","fmt","from","from","into","into","name","new","pr","to_owned","to_owned","try_from","try_from","try_into","try_into","type_id","type_id","vendor"],"q":[[0,"ci_info"],[4,"ci_info::types"]],"d":["Loads and returns the CI info of the current environment.","Returns true if a CI environment is detected.","This function will modify the current environment …","types","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI info","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","CI vendor","Supported vendors enum","CI vendor","CI vendor","CI vendor","CI vendor","","","","","The branch name for the given build","True if CI environment","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","vendor name","Returns new instance","True if currently running a PR build, None if unknown","","","","","","","","","The CI vendor"],"i":[0,0,0,0,3,3,3,3,3,3,3,3,3,3,3,0,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,0,3,3,3,3,3,1,3,1,1,1,3,1,3,1,1,3,1,3,1,3,1,3,1,1,1,1,3,1,3,1,3,1,3,1,1],"f":[[[],1],[[],2],[1],0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,[[]],[[]],[[]],[[]],0,0,[3,3],[1,1],[[]],[[]],[[],1],[[3,3],2],[[1,1],2],[[3,4],5],[[1,4],5],[[]],[[]],[[]],[[]],0,[[],1],0,[[]],[[]],[[],6],[[],6],[[],6],[[],6],[[],7],[[],7],0],"c":[],"p":[[3,"CiInfo"],[15,"bool"],[4,"Vendor"],[3,"Formatter"],[6,"Result"],[4,"Result"],[3,"TypeId"]]}\ }'); if (typeof window !== 'undefined' && window.initSearch) {window.initSearch(searchIndex)}; if (typeof exports !== 'undefined') {exports.searchIndex = searchIndex}; diff --git a/docs/api/src/ci_info/config.rs.html b/docs/api/src/ci_info/config.rs.html index 8516538..63282f5 100644 --- a/docs/api/src/ci_info/config.rs.html +++ b/docs/api/src/ci_info/config.rs.html @@ -450,17 +450,6 @@ 450 451 452 -453 -454 -455 -456 -457 -458 -459 -460 -461 -462 -463
//! # config
 //!
 //! Predefined config of CI vendors.
@@ -807,17 +796,6 @@
         branch_name_env: Some("SEMAPHORE_GIT_BRANCH".to_string()),
     });
 
-    config.push(VendorConfig {
-        name: "Shippable".to_string(),
-        vendor: Vendor::Shippable,
-        ci_env: EnvValue::Exists("SHIPPABLE".to_string()),
-        pr_env: Some(EnvValue::Value(
-            "IS_PULL_REQUEST".to_string(),
-            "true".to_string(),
-        )),
-        branch_name_env: None,
-    });
-
     config.push(VendorConfig {
         name: "Solano CI".to_string(),
         vendor: Vendor::SolanoCI,
diff --git a/docs/api/src/ci_info/types.rs.html b/docs/api/src/ci_info/types.rs.html
index 6519149..6e96d84 100644
--- a/docs/api/src/ci_info/types.rs.html
+++ b/docs/api/src/ci_info/types.rs.html
@@ -169,8 +169,6 @@
 169
 170
 171
-172
-173
 
//! # types
 //!
 //! Defines the various types and aliases.
@@ -262,8 +260,6 @@
     /// CI vendor
     Semaphore,
     /// CI vendor
-    Shippable,
-    /// CI vendor
     SolanoCI,
     /// CI vendor
     SourceHut,
diff --git a/src/config.rs b/src/config.rs
index 1321e76..8affd5e 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -344,17 +344,6 @@ pub(crate) fn create() -> Vec {
         branch_name_env: Some("SEMAPHORE_GIT_BRANCH".to_string()),
     });
 
-    config.push(VendorConfig {
-        name: "Shippable".to_string(),
-        vendor: Vendor::Shippable,
-        ci_env: EnvValue::Exists("SHIPPABLE".to_string()),
-        pr_env: Some(EnvValue::Value(
-            "IS_PULL_REQUEST".to_string(),
-            "true".to_string(),
-        )),
-        branch_name_env: None,
-    });
-
     config.push(VendorConfig {
         name: "Solano CI".to_string(),
         vendor: Vendor::SolanoCI,
diff --git a/src/config_test.rs b/src/config_test.rs
index 4bb9dcf..41686d4 100644
--- a/src/config_test.rs
+++ b/src/config_test.rs
@@ -1168,57 +1168,6 @@ fn get_pr_semaphore() {
     assert_eq!(info.branch_name.unwrap(), "mock_branch");
 }
 
-#[test]
-fn get_no_pr_shippable() {
-    let info = get_with_env(TestVendorConfig {
-        ci_env: EnvValue::Exists("SHIPPABLE".to_string()),
-        pr_env: None,
-        branch_name_env: None,
-    });
-
-    assert!(info.ci);
-    assert!(!info.pr.unwrap());
-    assert_eq!(info.vendor.unwrap(), Vendor::Shippable);
-    assert_eq!(info.name.unwrap(), "Shippable");
-    assert!(info.branch_name.is_none());
-}
-
-#[test]
-fn get_no_pr2_shippable() {
-    let info = get_with_env(TestVendorConfig {
-        ci_env: EnvValue::Exists("SHIPPABLE".to_string()),
-        pr_env: Some(EnvValue::Value(
-            "IS_PULL_REQUEST".to_string(),
-            "123".to_string(),
-        )),
-        branch_name_env: None,
-    });
-
-    assert!(info.ci);
-    assert!(!info.pr.unwrap());
-    assert_eq!(info.vendor.unwrap(), Vendor::Shippable);
-    assert_eq!(info.name.unwrap(), "Shippable");
-    assert!(info.branch_name.is_none());
-}
-
-#[test]
-fn get_pr_shippable() {
-    let info = get_with_env(TestVendorConfig {
-        ci_env: EnvValue::Exists("SHIPPABLE".to_string()),
-        pr_env: Some(EnvValue::Value(
-            "IS_PULL_REQUEST".to_string(),
-            "true".to_string(),
-        )),
-        branch_name_env: None,
-    });
-
-    assert!(info.ci);
-    assert!(info.pr.unwrap());
-    assert_eq!(info.vendor.unwrap(), Vendor::Shippable);
-    assert_eq!(info.name.unwrap(), "Shippable");
-    assert!(info.branch_name.is_none());
-}
-
 #[test]
 fn get_no_pr_solano_ci() {
     let info = get_with_env(TestVendorConfig {
diff --git a/src/types.rs b/src/types.rs
index b1a7cdf..cfe30a9 100644
--- a/src/types.rs
+++ b/src/types.rs
@@ -89,8 +89,6 @@ pub enum Vendor {
     /// CI vendor
     Semaphore,
     /// CI vendor
-    Shippable,
-    /// CI vendor
     SolanoCI,
     /// CI vendor
     SourceHut,