Skip to content

Instantly share code, notes, and snippets.

<VirtualHost _default_:80>
DocumentRoot "D:/Redmine-BITNAMI/apache2/htdocs"
<Directory "D:/Redmine-BITNAMI/apache2/htdocs">
Options Indexes FollowSymLinks
AllowOverride All
<IfVersion < 2.3 >
Order allow,deny
Allow from all
</IfVersion>
@KingBain
KingBain / gist:7d3e76d97c3227847f20
Created April 24, 2015 15:46
Error install redmine_checklists plugin
D:\Redmine\3.0.1\apps\redmine\htdocs\plugins>bundle exec rake redmine:plugins NAME=redmine_checklists RAILS_ENV=production
DL is deprecated, please use Fiddle
(in D:/Redmine/3.0.1/apps/redmine/htdocs)
DL is deprecated, please use Fiddle
rake aborted!
NameError: undefined local variable or method `generated_feature_methods' for #<Class:0x67b0ff0>
D:/Redmine/3.0.1/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activerecord-4.2.0/lib/active_record/dynamic_matchers.rb:26:in `method_missing'
D:/Redmine/3.0.1/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/protected_attributes-1.0.5/lib/active_record/mass_assignment_security/nested_attributes.rb:30:in `block in accepts_nested_attributes_for'
D:/Redmine/3.0.1/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/protected_attributes-1.0.5/lib/active_record/mass_assignment_security/nested_attributes.rb:16:in `each'
D:/Redmine/3.0.1/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/protected_attributes-1.0.5/lib/active_record/mass_assignment_security/nested_attribute
status = sysDrive.EnableKeyProtectors()
if status <> 0 then
logger.LogError(now & " " & sysDrive.DeviceID & " Unable to resume bitlocker. Error: " & hex(status))
else
shell.RegDelete "HKEY_LOCAL_MACHINE\SOFTWARE\"&cicRegistryFolderName&"\"&registryFolder&"\WhenBitlockerPaused"
logger.Log(now & " Bitlocker has been resumed")
end if
@KingBain
KingBain / RotateLogs.psi
Created August 19, 2015 19:48
Rotate Logs
<#
Public Domain License
Modified by kingbain
.SYNOPSIS
Clean up and rotate files
.DESCRIPTION
@KingBain
KingBain / Get-BitlockerProtection.ps1
Last active May 5, 2016 14:06
Bitlocker Compliance detection for C: drive.
<#
*********************************************************************************************************
* *
*** This Powershell Script is used to get the Bitlocker protection status ***
* *
*********************************************************************************************************
* Created by Ioan Popovici, 13/11/2015 | Requirements Powershell 3.0 *
* ======================================================================================================*
* Modified by | Date | Revision | Comments *
*_______________________________________________________________________________________________________*
@KingBain
KingBain / Configure-AutoOn.ps1
Created June 15, 2016 13:00
Powershell script to configure BIOS Aut-On settings
param(
[switch]$Clear,
[string]$Time,
[int]$Window,
[string[]]$Days
)
function Get-AutoOn(){
$object = New-Object -TypeName PSObject
try {
@KingBain
KingBain / waitForKeyElements.js
Created May 26, 2017 13:01 — forked from BrockA/waitForKeyElements.js
A utility function, for Greasemonkey scripts, that detects and handles AJAXed content.
/*--- waitForKeyElements(): A utility function, for Greasemonkey scripts,
that detects and handles AJAXed content.
Usage example:
waitForKeyElements (
"div.comments"
, commentCallbackFunction
);
@KingBain
KingBain / CanWeJam.rb
Created December 6, 2019 05:15
Can We Jan
require 'open-uri'
require 'csv'
require 'ostruct'
target = open('https://raw.githubusercontent.com/isthisblocked/isthisblockedinmydepartment.ca/master/src/data/organizations.csv')
targetCSV = CSV.parse(target, headers: true)
orgNames = Hash.new
targetCSV.each do |x|
@KingBain
KingBain / hide-wikijs-panel.user.js
Last active August 25, 2022 12:43
Removes the left nav panel for wiki.js users, works in tampermonkey and greasemonkey
// ==UserScript==
// @name hide-wikijs-panel
// @author John Bain
// @version 0.2.1
// @match https://docs.scienceprogram.cloud/*
// @exclude https://docs.scienceprogram.cloud/a/*
// @description Hides the Nav Panel in Wiki.js
// @require https://gist.github.com/raw/2625891/waitForKeyElements.js
// @require https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js
// @grant GM_addStyle
@KingBain
KingBain / Veggie_Agile.js
Last active May 3, 2023 17:57
Veggie Agile
// ==UserScript==
// @name Veggie Agile
// @author John Bain
// @version 0.1
// @description Change all GitHub words for agile to veggies
// @match *://github.com/*project*
// @icon https://raw.githubusercontent.com/xthexder/wide-github/master/icons/icon.png
// @updateURL https://gist.githubusercontent.com/KingBain/a7d542747952a3b92837748809b4d3aa/raw/Veggie_Agile.js
// @downloadURL https://gist.githubusercontent.com/KingBain/a7d542747952a3b92837748809b4d3aa/raw/Veggie_Agile.js
// @grant none