Publishing artifacts with AWS Codeartifact and GitHub Packages
- Blog Post: Publishing artifacts with AWS Codeartifact and GitHub Packages
- GitHub repository with full code details: reach-now/codeartifact-packages-publishing
aws cli
aws cli
#!/usr/bin/env sh | |
function update() { | |
for i in `asdf plugin list` | |
do | |
CURRENT_VERSION=`asdf current $i | awk '{print $2}'` | |
LATEST_VERSION=`asdf latest $i` | |
echo "Working with $i current version $CURRENT_VERSION but latest version is $LATEST_VERSION" | |
if [[ $(semver_check $LATEST_VERSION $CURRENT_VERSION) -lt 0 ]]; then | |
echo "Needs to update" |
#!/usr/bin/env bash | |
# This script manages a simple tagging lifecycle: current -> previous -> outdated. | |
# It is meant to be used with a bucket lifecycle policy, in order to delete all outdated tags. | |
# Why ? | |
# The deployment bucket has to be cleaned regularly, otherwise it will become a mess. | |
# However, having a simple lifecycle policy based on time is dangerous | |
# Deleting old objects without a recent deployment can lead to deletion of currently used assets. | |
# In case of error in the next deployment, the stack will try to rollback and will not find assets |
git fetch --all -p; git branch -vv | grep ": gone]" | awk '{ print $1 }' | xargs -r -n 1 git branch -D |
'use strict' | |
const Busboy = require('busboy') | |
const XLSX = require('xlsx') | |
function parseMultipartFormData(input, contentType) { | |
return new Promise((resolve, reject) => { | |
const buffers = [] | |
const busboy = new Busboy({ | |
headers: { 'content-type': contentType }, |
var Types = new Map(); | |
Types.set(Array, function(v) { | |
var l = v.length; i = 0, a = Array(l); | |
for (i; i<l; i++) { | |
a[i] = v[i]; | |
} | |
return a; | |
}); | |
Types.set(Number, function(v) { | |
return v * 1; |
import { After, Status } from 'cucumber'; | |
import { resolve } from 'path'; | |
const fs = require('fs'); | |
const diffFolder = resolve(process.cwd(), '.tmp/report/screenshots/image-comparison/diff/'); | |
const screenshotFolder = resolve(process.cwd(), '.tmp/screenshots/'); | |
/** | |
* The After hook that checks the scenario status and creates a | |
* screemshot if needed |