Skip to content

Instantly share code, notes, and snippets.

View 64BitChris's full-sized avatar

Chris Shellenbarger 64BitChris

View GitHub Profile
<repository>
<id>spring-snapshots</id>
<name>Spring Snapshots</name>
<url>https://repo.spring.io/snapshot</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
<repository>
<id>spring-releases</id>
<name>Spring Releases</name>
<url>https://repo.spring.io/release</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repositories>
<repository>
<id>central</id>
<name>Maven Central</name>
<layout>default</layout>
<url>https://repo1.maven.org/maven2</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<repositories>
<repository>
<id>central</id>
<name>Maven Central</name>
<layout>default</layout>
<url>https://repo1.maven.org/maven2</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
@64BitChris
64BitChris / bitbucket-pipelines.yml
Created October 30, 2018 16:53
Example BitBucket Pipeline YML file for Maven Projects
image: atlassian/default-image:2
pipelines:
branches:
master: # Trigger this for any pushes to the master branch.
- step:
name: Build and Deploy Snapshot Artifact
trigger: automatic
caches:
- maven # Cache any dependencies we download, speeds up build times.
@64BitChris
64BitChris / settings.xml
Created October 30, 2018 16:52
Same Settings After Generated
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
https://maven.apache.org/xsd/settings-1.0.0.xsd">
<!-- Complete Documentation for the settings.xml file can be found at https://maven.apache.org/settings.html -->
<!--
- <servers> specify the repositories we deploy or release artifacts to.
-
@64BitChris
64BitChris / run.sh
Created October 30, 2018 16:48
run create-settings.sh
$ CLOUDREPO_USERNAME=my-user CLOUDREPO_PASSPHRASE=my-passphrase ./create-settings.sh
@64BitChris
64BitChris / repositories.xml
Created October 30, 2018 16:47
Repositories Settings for BitBucket Pipelines and CloudRepo
<!--
- The <repositories> tag is used when you wish to define a maven repository that you want to READ artifacts from.
-
- While not used in this example, we leave this here in this pom for completeness. If you want to read artifacts from
- the repositories that you configured above in <distributionManagement> then these are the tags you'd need.
-->
<repositories>
<repository>
<id>io.cloudrepo.maven.releases</id>
<name>CloudRepo Release Repositories</name>
@64BitChris
64BitChris / distributionManagement.xml
Created October 30, 2018 16:45
Distribution Management Settings for BitBucket Pipelines and a Maven Repository
<!--
- Distribution Management tells maven where to deploy your artifacts when the 'mvn deploy' command is used.
-
- Repository Parameters:
- id: A unique id for each repository, this must correspond to an entry in the settings.xml file used by maven
usually located in ~/.m2/settings.xml or specified using the mvn command's -s parameter
(ie: mvn -s settings.xml deploy).
You can keep the ids as specified below as long as you have only one set (snapshot and release) of
CloudRepo maven repositories, otherwise you'll need to have a unique id in your settings.xml file for each
@64BitChris
64BitChris / file-size.pipe.ts
Created April 18, 2018 23:33 — forked from JonCatmull/file-size.pipe.ts
Angular2 + TypeScript file size Pipe/Filter. Convert bytes into largest possible unit. e.g. 1024 => 1 KB
import { Pipe, PipeTransform } from '@angular/core';
/*
* Convert bytes into largest possible unit.
* Takes an precision argument that defaults to 2.
* Usage:
* bytes | fileSize:precision
* Example:
* {{ 1024 | fileSize}}
* formats to: 1 KB