Skip to content

Instantly share code, notes, and snippets.

@RudolfVonKrugstein
RudolfVonKrugstein / v2.go
Created October 5, 2019 13:15
second version
func readInput(c chan string) {
l, err := readline.New(" > ")
if err != nil {
panic(err)
}
defer l.Close()
for {
line, err := l.Readline()
if err != nil {
panic(err)
@RudolfVonKrugstein
RudolfVonKrugstein / v1.go
Created October 5, 2019 13:14
First version
package main
import (
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/session"
"github.com/aws/aws-sdk-go/service/polly"
"github.com/chzyer/readline"
"io/ioutil"
"os"
"os/exec"

Keybase proof

I hereby claim:

  • I am RudolfVonKrugstein on github.
  • I am nathanhuesken (https://keybase.io/nathanhuesken) on keybase.
  • I have a public key whose fingerprint is 2048 C392 E425 7171 74BC 6996 984A A729 EC76 04F6

To claim this, I am signing this object:

### Keybase proof
I hereby claim:
* I am RudolfVonKrugstein on github.
* I am nathanhuesken (https://keybase.io/nathanhuesken) on keybase.
def areWeInPoll(poll, userId):
for participant in poll["participants"]:
if participant["userId"] == userId:
return True
return False
with requests.Session() as s:
res = s.post("https://doodle.com/api/v2.0/users/oauth/token", json={ "email": "<user-name>", "password": "<password>"} ).json()
name = res["name"]
/usr/local/lib/node_modules/appium/build/lib/main.js --debug-log-spacing
[Appium] Welcome to Appium v1.6.4
[Appium] Non-default server args:
[Appium] debugLogSpacing: true
[Appium] Appium REST http interface listener started on 0.0.0.0:4723
[HTTP] --> POST /wd/hub/session {"requiredCapabilities":{},"desiredCapabilities":{"platformVersion":"10.3","deviceName":"iPhone 6","automationName":"XCUITest","platformName":"iOS","app":"/Users/Shared/Jenkins/Home/workspace/OM-App-Pipeline/OM-App/OM_App.iOS/bin/iPhoneSimulator/Debug/OM_App.iOS.app"}}
[debug] [MJSONWP] Calling AppiumDriver.createSession() with args: [{"platformVersion":"10.3","deviceName":"iPhone 6","automationName":"XCUITest","platformName":"iOS","app":"/Users/Shared/Jenkins/Home/workspace/OM-App-Pipeline/OM-App/OM_App.iOS/bin/iPhoneSimulator/Debug/OM_App.iOS.app"},{},null,null,null]
[debug] [BaseDriver] Event 'newSessionRequested' logged at 1491894405728 (09:06:45 GMT+0200 (CEST))
[Appium] Creating new XCUITestDriver (v2.27.2) session
[Appium] Capabilit
<?xml version="1.0" encoding="UTF-8"?><AppiumAUT><XCUIElementTypeApplication type="XCUIElementTypeApplication" name="OM_App" label="OM_App" enabled="true" x="0" y="0" width="375" height="667">
<XCUIElementTypeWindow type="XCUIElementTypeWindow" enabled="true" x="0" y="0" width="375" height="667">
<XCUIElementTypeOther type="XCUIElementTypeOther" enabled="true" x="0" y="0" width="375" height="667">
<XCUIElementTypeOther type="XCUIElementTypeOther" enabled="true" x="0" y="0" width="375" height="667">
<XCUIElementTypeNavigationBar type="XCUIElementTypeNavigationBar" name="Configuration" enabled="true" x="0" y="20" width="375" height="44">
<XCUIElementTypeStaticText type="XCUIElementTypeStaticText" value="Configuration" name="Configuration" label="Configuration" enabled="true" x="133" y="28" width="110" height="27"/>
</XCUIElementTypeNavigationBar>
<XCUIElementTypeOther type="XCUIElementTypeOther" enabled="true" x="0" y="0" width="375" height="667">
<XCUIEl
[Appium] Welcome to Appium v1.6.3
[Appium] Non-default server args:
[Appium] port: 4724
[Appium] defaultDevice: true
[Appium] debugLogSpacing: true
[Appium] defaultCapabilities: { platformVersion: '10.3',
platformName: 'iOS',
showIOSLog: true }
[Appium] platformName: 'iOS'
[Appium] showIOSLog: true
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
<html>
<body>
<div>
<svg xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:ns0="http://www.w3.org/2000/svg" xmlns:ns1="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:ns2="http://www.inkscape.org/namespaces/inkscape" xmlns:ns4="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" baseProfile="full" height="49.6062994" version="1.1" viewBox="0,0,85.0393704,49.6062994" width="85.0393704" xmlns="http://www.w3.org/2000/svg" xmlns:ev="http://www.w3.org/2001/xml-events" xmlns:xlink="http://www.w3.org/1999/xlink"><defs /><text style="font-size:31px;text-align:middle;" x="42.5196852" y="35.433071">66</text><g transform="matrix(1.0,0.0,0.0,1.0,7.0866142,7.0866142)"><ns0:defs id="defs4" />
<ns1:namedview bordercolor="#666666" borderopacity="1.0" id="base" pagecolor="#ffffff" showgrid="false" units="mm" ns2:current-layer="layer1" ns2:cx="28.711684" ns2:cy="2.9836586" ns2:document-units="px" ns2:pageopacity="0.0" ns2:pageshadow="2" ns2:window-height="1018" ns2:window-maximi