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
COMPONENT_NAME=timepicker | |
GREP_E_MATCHER="(timepicker|other_string)" | |
TMP_BRANCH=$COMPONENT_NAME-tmp | |
git checkout -b $TMP_BRANCH | |
git filter-branch -f --prune-empty --index-filter 'git ls-files | grep -v -E "$GREP_E_MATCHER" | xargs git rm --cached --ignore-unmatch --quiet' HEAD | |
git checkout --orphan $COMPONENT_NAME |
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
#!/usr/bin/env bash | |
JAVA_FILE_ENDING="*.java" | |
JAVA_MARKER="\/* TODO: Check for data center *\/" | |
DIRECTORY=$1 | |
if [ -z "$DIRECTORY" ]; then | |
echo "Usage: $0 <directory>" |
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
var moviePilotRatingAnalyser = { | |
movieId: function () { | |
return jQuery("[data-type='Movie']").data('id'); | |
}, | |
ratings: function () { | |
return this.ratingData.map(function (rating) { | |
return rating.value || 0; | |
}); | |
}, | |
average: function () { |
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
# List all queries that are running longer than one minute | |
SELECT | |
pid, | |
now() - pg_stat_activity.query_start AS duration, | |
query, | |
state | |
FROM pg_stat_activity | |
WHERE (now() - pg_stat_activity.query_start) > interval '1 min' | |
ORDER BY duration; |
OlderNewer