Skip to content

Instantly share code, notes, and snippets.


Block or report user

Report or block cjcolvar

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
cjcolvar /
Last active Jan 17, 2020
Using Visual Studio Code's Live Share plugin to remotely participate during Developer Congress

Install Visual Studio Code. It is free and has Win/Mac/Linux versions.

Next install the Live Share Extension Pack. This includes the Live Share plugin and the Live Share Audio and Chat plugins.

Once these are installed, read the quickstart for joining a live share.

If you want, read the longer documentation about all you can share (editors, shells, servers, etc.) during the live share.

During the Dev Congress, one person can create the live share, start an audio call, send the live share link on slack, and then others will join. The host doesn't need to be the person leading the swarm but should

cjcolvar /
Last active Oct 22, 2019
Samvera Connect 2019 - CircleCI Workshop

Samvera Connect 2019 - CircleCI Workshop

We're going to run through converting a simple ruby gem from a Travis CI build to a CircleCI build using the Samvera orb.

Setup Code

  1. Fork ruby-rdf/linkeddata to your personal github space
  2. Checkout your fork locally: git clone<username>/linkeddata.git
  3. Enter checkout directory: cd linkeddata
  4. Run bundle install: bundle install
  5. Verify the tests pass: bundle exec rspec
View index.html
<!DOCTYPE html>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Simple Kanji Game</title>
<script src=""></script>
<link href="" rel="stylesheet" type="text/css" />
<script src=""></script>
<style id="jsbin-css">
cjcolvar / ntriples_reindexing.rb
Last active Sep 4, 2018
Monkey-patch initializer to request ntriples when reindexing to avoid timeouts
View ntriples_reindexing.rb
ActiveFedora::Fedora.class_eval do
def ntriples_connection
authorized_connection.tap { |conn| conn.headers['Accept'] = 'application/n-triples' }
def build_ntriples_connection, omit_ldpr_interaction_model: true), root_resource_path)
cjcolvar / gist:a7c26de736e5dede6381ea6b31264a16
Created Nov 2, 2017
Variations migration script via batch ingest from Paul Hoffman
View gist:a7c26de736e5dede6381ea6b31264a16
use strict;
use warnings;
use XML::LibXSLT;
use XML::LibXML;
use POSIX qw(strftime);
use File::Basename qw(dirname basename);
use Getopt::Long
cjcolvar / gist:1ca9326120e99ab1bddde0f66c4877fc
Created Jul 31, 2017
DescendentFetcher which partitions into model names passed, skips PairTree nodes, and stops after first level of non-PairTree nodes
View gist:1ca9326120e99ab1bddde0f66c4877fc
module ActiveFedora
module Indexing
# Finds all descendent URIs of a given repo URI (usually the base URI).
# This is a slow and non-performant thing to do, we need to fetch every single
# object from the repo.
# The DescendantFetcher is also capable of partitioning the URIs into "priority" URIs
# that will be first in the returned list. These prioritized URIs belong to objects
# with certain hasModel models. This feature is used in some hydra apps that need to
cjcolvar / .fcrepo_wrapper
Created May 19, 2017
fcrepo_wrapper config that enables jmx
View .fcrepo_wrapper
# Place any default configuration for solr_wrapper here
port: 8984
enable_jms: false
fcrepo_home_dir: tmp/fcrepo4-development-data
- '-Dfcrepo.log.http.api=WARN'
- '-Dfcrepo.log.kernel=ERROR'
- '-Dfcrepo.home=tmp/fcrepo4-development-data'
- '-Dfcrepo.spring.jms.configuration=file:///Users/cjcolvar/.rvm/gems/ruby-2.3.1/gems/fcrepo_wrapper-0.7.0/data/spring-noop.xml'
- ''
cjcolvar / gist:b56aa87848d6cc519a3f7c36cd24db56
Created Jun 23, 2016
Options for determining what migrations need to be run
View gist:b56aa87848d6cc519a3f7c36cd24db56
[cjcolvar@localhost avalon]$ bundle exec rake db:version
Current version: 20160511155417
[cjcolvar@localhost avalon]$ bundle exec rake db:migrate:status
database: /home/cjcolvar/Code/avalon/avalon/db/development.sqlite3
Status Migration ID Migration Name
up 20120202180525 Devise create users
up 20120202180540 Create searches
cjcolvar / example.vtt
Created Mar 9, 2016
Example vtt file for testing
View example.vtt
00:00:01.000 --> 00:00:10.000
This is the first line of text, displaying from 1-10 seconds
00:00:15.000 --> 00:00:20.000
And the second line of text
separated over two lines
cjcolvar / gist:a7ead7472e9ffd6673f1
Created Aug 3, 2015
Matterhorn distribute-hls stacktrace
View gist:a7ead7472e9ffd6673f1
2015-07-28 17:45:16 INFO (AbstractCmdlineEncoderEngine:237) - Executing encoding command: /usr/bin/ffmpeg -i /usr/local/matterhorn/work/opencast/workspace/mediapackage/8677661e-0e40-4585-a94d-6ae8c4af664d/bf058e85-3770-4607-b10e-82b09f4c7bec/filename.mp4 -codec copy -map 0 -bsf h264_mp4toannexb -f segment -segment_list /usr/local/matterhorn/work/opencast/workspace/mediapackage/8677661e-0e40-4585-a94d-6ae8c4af664d/bf058e85-3770-4607-b10e-82b09f4c7bec/filename_b20051ba-dc9c-409b-b62d-6ad46e068dce.m3u8 -segment_time 10 /usr/local/matterhorn/work/opencast/workspace/mediapackage/8677661e-0e40-4585-a94d-6ae8c4af664d/bf058e85-3770-4607-b10e-82b09f4c7bec/filename_b20051ba-dc9c-409b-b62d-6ad46e068dce-%03d.ts
2015-07-28 17:45:16 INFO (AbstractCmdlineEncoderEngine:261) - Video track filename.mp4 successfully encoded using profile 'profile.hls.http'
2015-07-28 17:45:16 WARN (HLSDistributionServiceImpl:269) - Error distributing
You can’t perform that action at this time.