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
#!/bin/bash | |
# Chmod this u+x and put it in your $PATH | |
# Open the first .sublime-project or the working dir | |
# in SublimeText assumes that `subl` is in your path | |
for f in ./*.sublime-project; do | |
if [ -e "$f" ] | |
then | |
subl --project "$f" |
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
def replace_run_in_sequence(seq_r_id, new_run_id) | |
new_run = Run.find(new_run_id) | |
sequence_run = SequenceRun.find(seq_r_id) | |
old_run = sequence_run.runs.detect { |r| r.activity_id == new_run.activity_id } | |
if old_run | |
clone_run(old_run,new_run) | |
if new_run.percent_complete > old_run.percent_complete | |
puts "removing run #{old_run.id}" | |
sequence_run.runs.delete(old_run) |
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
[ | |
{ | |
"type":"open_response", | |
"question_id":"4462", | |
"answer":"The increase demands during day because it might be something you need it for and the same thing through the season.", | |
"is_final":false | |
}, | |
{ | |
"type":"open_response", | |
"question_id":"4463", |
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
def run_report(key) | |
r = Run.find_by_key(key) | |
r.sequence_run.runs.each do |r| | |
puts [r.id, r.activity_id, r.remote_endpoint, r.collaboration_run||"none", run.dirty?].join(", “) | |
end | |
end |
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
ssh [email protected] | |
deploy@ip-10-30-155-89:~$ cd /web/portal/current | |
deploy@ip-10-30-155-89:/web/portal/current$ git log --pretty=oneline -10 | |
cac87bea8fea23984101611962de5df0be34c0f6 fixes: "Preview" doesn't work when editing "Home Page Content " [#77842658] | |
8a35e2e5204d3032947029341e22cf411fbff245 Add genigames_data feature to learn portal | |
ef36bb660ee8c69b0d5bfc25a7575b508ecdff98 Add genigame_connector gem; bump json gem | |
c056e16d086a85aeddb821f48830985435f0660c Add geniverse_remote_auth feature to learn portal |
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
<h3> Testing </h3> | |
<div> | |
The has project video: | |
</div> | |
<div style="border: 1px solid black; padding: 2em;"> | |
<video controls="" autoplay="true" width="500" preload="auto" name="media"> | |
<source src="https://has-production.s3.amazonaws.com/resources/HASPortalGuide/Resources/PortalGuideMovie-Broadband/Resources/PortalGuideMovie-Broadband%20-%20Broadband.m4v" type="video/mp4"> | |
</video> | |
</div> |
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
<div class="example-block"> | |
<!-- START RIBBON --> | |
<div class="ribbon ribbon-red"> | |
<div class="banner"> | |
<div class="text">30 Day Free Trial</div> | |
</div> | |
</div> | |
<!-- END RIBBON --> | |
<div class="headline">Professional</div> | |
<div class="tagline">Perfect for business growth.</div> |
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
<div class="example-block"> | |
<!-- START RIBBON --> | |
<div class="ribbon ribbon-red"> | |
<div class="banner"> | |
<div class="text">30 Day Free Trial</div> | |
</div> | |
</div> | |
<!-- END RIBBON --> | |
<div class="headline">Professional</div> | |
<div class="tagline">Perfect for business growth.</div> |
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
Last night CORS requests stopped working for us on Heroku. We are using rack-cors (0.2.8) middleware. | |
It rurns out our request paths didn't match our rackup configuration. | |
The real question might be: why were these requests returning correct HTTP headers in the past? | |
One hypothesis is that some other processes was cleaning up requests with redundant slashes. | |
The configuration: | |
#… | |
require 'rack/cors' |
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
import bpy | |
import colorsys | |
""" | |
cubify-image.py - Turns each pixel of an image into a scaled cube. | |
Noah Paessel | @knowuh - updated on 2022-02-13 (test w Blender 3.1b) | |
MIT license http://opensource.org/licenses/MIT | |
WARNING: This script will generate a thousands objects (one per image pixel) | |
I recommend only using it with image with less than 40,000 pixels (200x200). |