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
#!/usr/bin/ruby | |
require 'dotenv' | |
require 'aws' | |
require 'csv' | |
# patch instance to return runtime | |
class AWS::EC2::Instance | |
def runtime | |
@runtime ||= Time.now - launch_time |
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
Selenium.prototype.doTypePassword = function(locator, text) { | |
/** | |
* Sets the value of an input field the provided text | |
* | |
* @param locator an <a href="#locators">element locator</a> | |
*/ | |
// All locator-strategies are automatically handled by "findElement" | |
var element = this.page().findElement(locator); | |
this.browserbot.replaceText(element, text); |
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
from datetime import datetime, timedelta | |
# imports the required python libs | |
# helper function to get the end of the most recent hour | |
# as a python datetime object | |
# | |
# e.g. if the script calls this on 12/18 at 16:05 | |
# this returns a python date object for 12/18 at 15:59:59 | |
# | |
def most_recent_hour_end(): | |
return datetime.now().replace(minute=59, second=59, microsecond=0) |
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: "🏕️ Campsite" | |
on: | |
pull_request: | |
types: [opened] | |
branches: [ "main" ] | |
jobs: | |
notify-campsite: | |
runs-on: ubuntu-latest |