openapi_github/models/selected_actions.rs
1/*
2 * GitHub's official OpenAPI spec + Octokit extension
3 *
4 * OpenAPI specs from https://github.com/github/rest-api-description with the 'x-octokit' extension required by the Octokit SDKs
5 *
6 * The version of the OpenAPI document: 16.6.0
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct SelectedActions {
16 /// Whether GitHub-owned actions are allowed. For example, this includes the actions in the `actions` organization.
17 #[serde(rename = "github_owned_allowed", skip_serializing_if = "Option::is_none")]
18 pub github_owned_allowed: Option<bool>,
19 /// Whether actions from GitHub Marketplace verified creators are allowed. Set to `true` to allow all actions by GitHub Marketplace verified creators.
20 #[serde(rename = "verified_allowed", skip_serializing_if = "Option::is_none")]
21 pub verified_allowed: Option<bool>,
22 /// Specifies a list of string-matching patterns to allow specific action(s) and reusable workflow(s). Wildcards, tags, and SHAs are allowed. For example, `monalisa/octocat@*`, `monalisa/octocat@v2`, `monalisa/_*`. **Note**: The `patterns_allowed` setting only applies to public repositories.
23 #[serde(rename = "patterns_allowed", skip_serializing_if = "Option::is_none")]
24 pub patterns_allowed: Option<Vec<String>>,
25}
26
27impl SelectedActions {
28 pub fn new() -> SelectedActions {
29 SelectedActions {
30 github_owned_allowed: None,
31 verified_allowed: None,
32 patterns_allowed: None,
33 }
34 }
35}
36