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
import sys | |
import logging | |
from redash.query_runner import * | |
logger = logging.getLogger(__name__) | |
class Cassandra(BaseQueryRunner): | |
@classmethod | |
def configuration_schema(cls): |
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
@classmethod | |
def groups_name(cls, email): | |
t = db.session.query(F.unnest(cls.group_ids)).filter(cls.email == email) | |
print "New Q is coming !!!! {}".format(t) | |
print "!!!!!!!!!!!!!!!!!! {} !!!!!!!!".format(cls.group_ids) | |
return list([g.name for g in Group.query.filter(Group.id.in_(cls.query(t)))]) |
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
import requests | |
base_url = 'https://api.github.com' | |
def get_all_commits_count(owner, repo, sha): | |
first_commit = get_first_commit(owner, repo) | |
compare_url = '{}/repos/{}/{}/compare/{}...{}'.format(base_url, owner, repo, first_commit, sha) | |
commit_req = requests.get(compare_url) |
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
8.9.1 |
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
getNumOfCommitsOnBranchAfterDiverged() { | |
const numOfCommitsHere = exec.execRead(`git log --oneline HEAD | wc -l`); | |
const numOfCommitsInMasterBeforeDiverged = this.getNumOfCommitsOnMasterBeforeDiverged(); | |
return numOfCommitsHere - numOfCommitsInMasterBeforeDiverged; | |
} |
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
getNumOfCommitsOnMasterBeforeDiverged() { | |
let mergeBase; | |
try { | |
exec.execSyncSilent(`git fetch -q | true`); | |
mergeBase = exec.execRead(`git merge-base HEAD origin/master`); | |
} catch (ex) { | |
mergeBase = exec.execRead(`git merge-base HEAD master`); | |
} | |
const numOfCommits = exec.execRead(`git log --oneline ${mergeBase} | wc -l`); |
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
import React, { Component } from 'react' | |
import WordArt from 'react-wordart' | |
class Example extends Component { | |
render () { | |
return ( | |
<WordArt text='I Love WordArt' theme={`rainbow`} fontSize={100} /> | |
) | |
} |
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
pipeline { | |
agent { | |
node { | |
label 'master' | |
} | |
} | |
stages { | |
stage('android') { | |
steps { |
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
pipeline { | |
agent { | |
node { | |
label 'master' | |
} | |
} | |
stages { | |
stage('android') { | |
steps { |
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
# ~/.bashrc: executed by bash(1) for non-login shells. | |
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) | |
# for examples | |
# If not running interactively, don't do anything | |
case $- in | |
*i*) ;; | |
*) return;; | |
esac |
OlderNewer