I hereby claim:
- I am duboisf on github.
- I am duboisf (https://keybase.io/duboisf) on keybase.
- I have a public key ASBf_c8uO1Jj2wnFif-u4NuMe0xaCoynHsxksokHMWoSXQo
To claim this, I am signing this object:
| class Value: | |
| def __init__(self, val): | |
| self.val = val | |
| def invoker(x): | |
| def closure(y): | |
| print (x.val + y) | |
| return closure | |
| anObject = Value(5) |
| object WhileClosure extends Application { | |
| def While(cond: => Boolean)(body: => Unit): Unit = { | |
| if (cond) { | |
| body | |
| While(cond)(body) | |
| } | |
| } | |
| var x = 0 |
| import System.Environment (getArgs) | |
| main = | |
| getArgs >>= \[nbLines, filename] -> | |
| lines `fmap` readFile filename >>= \contents -> | |
| mapM_ putStrLn (drop (length contents - (read nbLines :: Int)) contents) |
| import scala.io.Source | |
| import java.io.File | |
| object Tail { | |
| def main(args: Array[String]) { | |
| val filesource = Source.fromFile(new File(args(1))) | |
| val lines = filesource.getLines().toList | |
| lines.drop(lines.length - args(0).toInt).map(println) | |
| filesource.close() | |
| } |
| import sbt._ | |
| import Keys._ | |
| object Test extends Build { | |
| lazy val listSources = TaskKey[Unit]("list-sources") | |
| def listSourcesTask = | |
| listSources <<= sources map { _ foreach println } |
| package gitjira.actions | |
| import gitjira.{Configuration, JIRA} | |
| case class DescribeAction(number: Int) extends GitJiraAction { | |
| def execute(config: Configuration, jira: JIRA) { | |
| val issue = jira getIssue number | |
| val output = """Issue: %s |
I hereby claim:
To claim this, I am signing this object:
| apiVersion: argoproj.io/v1alpha1 | |
| kind: Workflow | |
| metadata: | |
| generateName: test- | |
| namespace: argo | |
| spec: | |
| entrypoint: reproduce | |
| arguments: | |
| parameters: |
| #!/bin/bash | |
| # This script is intented to be used with kubectl when you don't want a plain | |
| # base64 encoded username:password token in your kube config. | |
| # It uses pass (https://www.passwordstore.org/) to store your password securely. | |
| # | |
| # To use it, download this script, make it executable (chmod +x | |
| # safe_userpass_token) move it to the ~/.kube/bin folder (create it if it | |
| # doesn't exist) and configure an entry in your ~/.kube/config under users, | |
| # like so: |
| #!/bin/bash | |
| # start openconnect tunnel and shell inside Linux network namespace | |
| # | |
| # this is a fork of schnouki's script, see original blog post | |
| # https://schnouki.net/posts/2014/12/12/openvpn-for-a-single-application-on-linux/ | |
| # | |
| # original script can be found here | |
| # https://gist.github.com/Schnouki/fd171bcb2d8c556e8fdf | |
| # ------------ adjust values below ------------ |