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
| import os | |
| import sys | |
| import requests | |
| import json | |
| from datetime import tzinfo, timedelta, datetime | |
| from dateutil.parser import parse | |
| POST_URL = 'https://slack.com/api/chat.postMessage' |
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
| git rm -r --cached . | |
| git add . | |
| git commit -m 'git cache cleared' | |
| git push |
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
| #local | |
| git branch --merged | grep -v '\*\|master\|develop' | xargs -n 1 git branch -d | |
| #remote | |
| git branch -r --merged | grep -v '\*\|master\|develop' | sed 's/origin\///' | xargs -n 1 git push --delete origin |
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
| #!/bin/bash | |
| ############ log file configuration ############## | |
| LOG_DIR="./" | |
| today=$(date +"%Y-%m-%d") | |
| logfile="$LOG_DIR/aem-content-refresh.log.$today" | |
| ############ Environment connections ############## | |
| # Source Author Slave | |
| SOURCE_AUTH_LOGIN="admin" |
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
| http://localhost:4502/bin/querybuilder.json? | |
| type=cq:Page& | |
| path=/content/geometrixx/en/products/triangle& | |
| group.p.or=true& | |
| group.1_property=jcr:content/cq:lastReplicationAction& | |
| group.1_property.value=Deactivate& | |
| group.2_property=jcr:content/cq:lastReplicationAction& | |
| group.2_property.operation=not |
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
| Uninstall a bundle (use http://localhost:4505/system/console/bundles to access the Apache Felix web console) | |
| curl -u admin:admin -daction=uninstall http://localhost:4505/system/console/bundles/"name of bundle" | |
| Install a bundle | |
| curl -u admin:admin -F action=install -F bundlestartlevel=20 -F | |
| bundlefile=@"name of jar.jar" http://localhost:4505/system/console/bundles | |
| Build a bundle | |
| curl -u admin:admin -F bundleHome=/apps/centrica/bundles/name of bundle -F | |
| descriptor=/apps/centrica/bundles/com.centrica.cq.wcm.core-bundle/name_of_bundle.bnd |
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
| chgrp -R admin /usr/local | |
| chmod -R g+w /usr/local | |
| chgrp -R admin /Library/Caches/Homebrew | |
| chmod -R g+w /Library/Caches/Homebrew |
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
| var app = require('express')(); | |
| var multer = require('multer') | |
| var lwip = require('lwip') | |
| app.use(multer({inMemory: true})) | |
| app.post('/', function (req, res) { | |
| var fileBuffer = req.files.file.buffer | |
| lwip.open(fileBuffer, 'jpg', function(err, image) { |
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
| javascript:(function(){ | |
| var TOUCH = '/editor.html'; | |
| var CLASSIC = '/cf'; | |
| var createURL = function(path, qs, hash) { | |
| var url = path; | |
| if(qs.length != 0 && !(qs.length == 1 && qs[0] == '')) { | |
| url += '?' + qs.join('&'); | |
| } | |
| url += hash; |
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
| #!/bin/bash | |
| if (( $# < 1 )) | |
| then | |
| echo "You should add more stuff ;)" | |
| echo "example: $0 ~/Desktop/file.json http://localhost:4502/content/copy" | |
| exit 1 | |
| fi | |
| j="$1" |
NewerOlder