This file contains 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
function ap_register_podcast_post_type() { | |
$labels = array( | |
'name' => __( 'Podcast Configs', 'newsuk' ), | |
'singular_name' => __( 'Podcast Config', 'newsuk' ), | |
'add_new' => __( 'New Podcast Config', 'newsuk' ), | |
'add_new_item' => __( 'Add New Podcast Config', 'newsuk' ), | |
'edit_item' => __( 'Edit Podcast Config', 'newsuk' ), | |
'new_item' => __( 'New Podcast Config', 'newsuk' ), | |
'view_item' => __( 'View Podcast Config','newsuk' ), |
This file contains 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
AlexaSkillFunction: | |
Type: AWS::Lambda::Function | |
Properties: | |
Code: | |
S3Bucket: | |
!Join | |
- '-' | |
- - 'my-bucket-name' | |
- !Ref 'AWS::Region' | |
- 'dev' |
This file contains 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
{ | |
"askcliResourcesVersion": "2020–03–31", | |
"profiles": { | |
"my-profile": { | |
"skillMetadata": { | |
"src": "./skill-package/pre-prod" | |
}, | |
# Specify code to be deployed to each region | |
This file contains 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
# Each time a deploy is triggered, the state is saved in a hidden file ask-states.json | |
# We use S3 Buckets to keep that in sync since the circle-ci container is stateless | |
# Get the latest deployment state from our S3 bucket ask-states.json | |
aws s3 cp s3://code-bucket/alexa-deployment/ask-states.json .ask/ask-states.json | |
# Deploy the Skill code with the ask cli (v2) | |
ask deploy -profile my-profile | |
# Save this new deployment state back to our S3 bucket |
This file contains 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
ask smapi create-skill-for-vendor - manifest file:../manifest.json - profile my-profile | |
{ | |
"skillId": "amzn1.ask.skill.blah-skill-id" | |
} |
This file contains 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 | |
# | |
# Flush all current rules from iptables | |
# | |
iptables -F | |
# | |
# Allow SSH connections on tcp port 22 | |
# This is essential when working on remote servers via SSH to prevent locking yourself out of the system | |
# | |
iptables -A INPUT -p tcp --dport 22 -j ACCEPT |
This file contains 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
angular.scenario.matcher("toContainUnordered", function(expected) { | |
var actual = this.future.value; | |
expected.forEach(function(element) { | |
if (actual.indexOf(element) < 0) { | |
throw new Error('Expected ['+actual+'] to contain "'+element+'"'); | |
} | |
}); |
This file contains 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
angular.scenario.dsl('selectBox', function() { | |
var chain = {}; | |
chain.options = function() { | |
return this.addFutureAction("select options'" + this.name, function($window, $document, done) { | |
var select = $document.elements(this.name); | |
var option = select.find('option'), items = []; | |
for(var i = 0; i < option.length; i++) { | |
items.push(option[i].text); |
This file contains 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 | |
# | |
# Flush all current rules from iptables | |
# | |
iptables -F | |
# | |
# Allow SSH connections on tcp port 22 | |
# This is essential when working on remote servers via SSH to prevent locking yourself out of the system | |
# | |
iptables -A INPUT -p tcp --dport 22 -j ACCEPT |
This file contains 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
rsconf = { | |
_id: "rs0", | |
members: [ | |
{ | |
_id: 0, | |
host: "127.0.0.1:27017" | |
}, | |
{ | |
_id: 1, | |
host: "127.0.0.1:37017" |
NewerOlder