###TextMate 2 save on focus lost create file .tm_properties in home folder and add saveOnBlur = true to it
mate $HOME/.tm_properties
and insert
saveOnBlur = true
require 'octokit' | |
class GithubCLI | |
# make sure to set your GITHUB_TOKEN in the environment | |
# also, the ocktokit gem needs to be installed | |
def get_repos_from_org_with_no_teams_assigned(github_org) | |
client = Octokit::Client.new :access_token => ENV['GITHUB_TOKEN'] | |
client.auto_paginate = true |
package tips.cloudnative.todotest; | |
// imports | |
import static tips.cloudnative.testauthentication.TestAuthentication.csrfHeaders; | |
@RunWith(SpringJUnit4ClassRunner.class) | |
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) | |
public class TodoTest { | |
@Test |
@Configuration | |
@Profile("development") | |
public class DevelopmentSecurityConfig extends WebSecurityConfigurerAdapter { | |
@Bean | |
public CsrfTokenRepository csrfTokenRepository() { | |
return CookieCsrfTokenRepository.withHttpOnlyFalse(); | |
} | |
@Override |
package tips.cloudnative.testauthentication; | |
import org.apache.commons.codec.binary.Base64; | |
import org.springframework.http.HttpHeaders; | |
public class TestAuthentication { | |
@Autowired | |
private CsrfTokenRepository csrfTokenRepository; |
package tips.cloudnative.todotest; | |
// imports | |
import static tips.cloudnative.testauthentication.TestAuthentication.basicAuthHeaders; | |
@RunWith(SpringJUnit4ClassRunner.class) | |
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) | |
public class TodoTest { | |
@Test |
package tips.cloudnative.testauthentication; | |
import org.apache.commons.codec.binary.Base64; | |
import org.springframework.http.HttpHeaders; | |
public class TestAuthentication { | |
public static HttpHeaders basicAuthHeaders() { | |
String plainCreds = "user:password"; | |
byte[] plainCredsBytes = plainCreds.getBytes(); | |
byte[] base64CredsBytes = Base64.encodeBase64(plainCredsBytes); |
// imports | |
@Configuration | |
@Profile("development") | |
public class DevelopmentSecurityConfig extends WebSecurityConfigurerAdapter { | |
@Autowired | |
public void configureGlobal(AuthenticationManagerBuilder auth) throws Exception { | |
auth | |
.inMemoryAuthentication() |
###TextMate 2 save on focus lost create file .tm_properties in home folder and add saveOnBlur = true to it
mate $HOME/.tm_properties
and insert
saveOnBlur = true
/* | |
This snippet first unselects all pipelines and then adds the specified ones back. | |
USAGE: | |
replace YOUR_PIPELINE_NAME with actual value | |
in your browser create a bookmark to any URL | |
edit the bookmark, replacing the URL with snippet build from the below template | |
voila: when you are on the goCD dashboard; click it and all pipelines except yours should disappear | |
*/ |