From 3371a8e808756c3d47599680505e29747211e04e Mon Sep 17 00:00:00 2001 From: Morgan Date: Thu, 13 Feb 2020 21:54:55 +0100 Subject: [PATCH] add groovy formating --- cheat/jenkins.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cheat/jenkins.md b/cheat/jenkins.md index f763823..2d70422 100644 --- a/cheat/jenkins.md +++ b/cheat/jenkins.md @@ -2,7 +2,9 @@ Execute in https://*INSTANCE*/script to reveal passwords from a password hash (obtained via Inspect Element on a Credential) -`hudson.util.Secret.decrypt('secret_hash')` +```groovy +hudson.util.Secret.decrypt('secret_hash') +``` ### Jenkins current jobs @@ -11,7 +13,7 @@ https://*INSTANCE*/computer/api/json?tree=computer[executors[currentExecutable[* ### Reveal all secrets Execute in https://*INSTANCE*/script to reveal all secrets -``` +```groovy import com.cloudbees.plugins.credentials.CredentialsProvider import com.cloudbees.plugins.credentials.Credentials import com.cloudbees.plugins.credentials.domains.Domain