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
// ==UserScript== | |
// @name Blogger Content Warning Skip | |
// @description Automatically skips the content warning on blogspot.com sites without reloading the page | |
// @match http://*.blogspot.com/* | |
// ==/UserScript== | |
var fireEvent = function(obj,evt){ | |
var fireOnThis = obj; | |
if (document.createEvent) { | |
var evObj = document.createEvent('MouseEvents'); |
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
# Usage: | |
# 1. Install required gems | |
# $ sudo gem install mechanize progressbar | |
# | |
# 2. Run with [vk.com|vkontakte.ru] [remixsid cookie] and [your_profile_id] | |
# $ ruby ./fetch.rb vk.com a528621366f13fb859a120b3a8c357dc98c1f7d93f5e66666662 8666676 | |
# 54% |ooooooooooooooooooooooooooooooooooooooooooooooooooooo | ETA: 0:01:49 | |
# | |
# 3. Enjoy the output |
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
// this is the background code... | |
// listen for our browerAction to be clicked | |
chrome.browserAction.onClicked.addListener(function (tab) { | |
// for the current tab, inject the "inject.js" file & execute it | |
chrome.tabs.executeScript(tab.ib, { | |
file: 'inject.js' | |
}); | |
}); |
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
If you have a huge repository (in size and in history) and want to add a subfolder | |
to your project as a submodule you can follow this example to save time and space | |
using git's shallow clone and shallow checkout feature. It is a bit more complicated | |
in this example because I assume that you want your submodule to track a non-default | |
branch, called `mybranch`, instead of the `master` branch. Things could probably get | |
a lot simpler when using the default branch. After following the commands in these | |
examples you can use `git submodule update` and `git submodule update --remote` as normal. |
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
#============================================================================== | |
# Copyright (c) Microsoft Corporation. All rights reserved. | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, | |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
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 Export-MFT { | |
<# | |
.SYNOPSIS | |
Extracts master file table from volume. | |
Version: 0.1 | |
Author : Jesse Davis (@secabstraction) | |
License: BSD 3-Clause | |
.DESCRIPTION |
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 Get-ParameterValues { | |
<# | |
.Synopsis | |
Get the actual values of parameters which have manually set (non-null) default values or values passed in the call | |
.Description | |
Unlike $PSBoundParameters, the hashtable returned from Get-ParameterValues includes non-empty default parameter values. | |
NOTE: Default values that are the same as the implied values are ignored (e.g.: empty strings, zero numbers, nulls). | |
.Example | |
function Test-Parameters { | |
[CmdletBinding()] |
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/sh | |
RESTORE=$(echo '\033[0m') | |
BOLD=$(echo '\033[1m') | |
GREEN=$(echo '\033[1;32m') | |
echo | |
echo ${GREEN} | |
echo "------------------------------" | |
echo " Installing prerequisites " | |
echo "------------------------------" | |
echo |
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
<# | |
.SYNOPSIS | |
Sets a known folder's path using SHSetKnownFolderPath. | |
.PARAMETER Folder | |
The known folder whose path to set. | |
.PARAMETER Path | |
The path. | |
#> | |
# USAGE: # Set-KnownFolderPath -KnownFolder 'Desktop' -Path '\\netserver\desktop\username\desktop' | |
# FROM: http://stackoverflow.com/questions/25709398/set-location-of-special-folders-with-powershell |
OlderNewer