This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~ $ cat toms.groovy | |
interface PRINT { | |
def LN = '\n\n' | |
def BREAK = '='*80 | |
} | |
println PRINT.BREAK | |
~ $ groovy toms.groovy | |
================================================================================ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void "Deleting a valid file from an existent part" (){ | |
given: | |
List <Metafile> sampleMetafiles = [new Metafile(id: '1111111111', filename: 'test.pdf', title: '', | |
description: '', uploadedOn: new Date(), | |
partId: '2222222222', uploadedBy: 'Alfred', userId: '333333333'), | |
new Metafile(id: '1111111112', filename: 'test2.pdf', title: '', | |
description: '', uploadedOn: new Date(), | |
partId: '2222222221', uploadedBy: 'Alfred', userId: '333333334') | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// I don't think there are scenarios where this is the best thing to do... | |
def donors = Donor.createCriteria().list(){ | |
eq('event', event) | |
} | |
if(params.sort == "firstName"){ | |
if(params.order == "asc"){ | |
donors.sort {it.firstName} | |
} else { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~ $ git clone [email protected]:jeffbrown/zaidkhandomaintest.git | |
Cloning into 'zaidkhandomaintest'... | |
remote: Enumerating objects: 111, done. | |
remote: Counting objects: 100% (111/111), done. | |
remote: Compressing objects: 100% (86/86), done. | |
remote: Total 111 (delta 11), reused 111 (delta 11), pack-reused 0 | |
Receiving objects: 100% (111/111), 627.88 KiB | 3.09 MiB/s, done. | |
Resolving deltas: 100% (11/11), done. | |
~ $ | |
~ $ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~ $ mn create-app someapp | |
| Application created at /Users/jeffscottbrown/someapp | |
~ $ | |
~ $ cd someapp | |
someapp $ | |
someapp $ mn --help | |
Usage: mn [-hvVx] [COMMAND] | |
Micronaut CLI command line interface for generating projects and services. | |
Application generation commands are: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void subscribeToMqtt(Message message) { | |
executor.cppMethod(); | |
} | |
public class TestExecutor { | |
static { | |
System.loadLibrary("native"); | |
} | |
public native String cppMethod(); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish To GCR | |
on: | |
push: | |
tags: | |
- 'v*' | |
env: | |
GCLOUD_REGION: ${{ secrets.GCLOUD_REGION }} | |
PROJECT_ORGANIZATION: ${{ secrets.PROJECT_ORGANIZATION }} | |
DOCKER_IMAGE: ${{ secrets.DOCKER_REGISTRY_URL }} | |
jobs: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is a bad idea | |
File f = File.createTempFile("temp", Long.toString(System.nanoTime())); | |
System.setErr(new PrintStream(new FileOutputStream(f)) { | |
@Override | |
public void println(String x) { | |
throw new RuntimeException(x); | |
} | |
}); | |
System.err.println("overflow!"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~ $ git clone [email protected]:jeffbrown/stevemaystermkdir.git | |
Cloning into 'stevemaystermkdir'... | |
remote: Enumerating objects: 23, done. | |
remote: Counting objects: 100% (23/23), done. | |
remote: Compressing objects: 100% (17/17), done. | |
remote: Total 23 (delta 0), reused 23 (delta 0), pack-reused 0 | |
Receiving objects: 100% (23/23), 60.03 KiB | 543.00 KiB/s, done. | |
~ $ | |
~ $ | |
~ $ cd stevemaystermkdir |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~ $ pwd | |
/Users/jeffscottbrown | |
~ $ | |
~ $ ls stevemayster | |
~ $ | |
~ $ cat stevewantstocreatedirectory.groovy | |
def nametest = 'try' | |
def patchPath = '/Users/jeffscottbrown/stevemayster' | |
def fileName = "${patchPath}/${nametest}" |