Skip to content

Instantly share code, notes, and snippets.

View ThatKalle's full-sized avatar
👋

Kalle Lilja ThatKalle

👋
View GitHub Profile
@morozgrafix
morozgrafix / slack_slash_command_template.php
Created January 19, 2016 20:24
Basic Slack Slash Command Bot Template in PHP
<?php
// Authorized team tokens that you would need to get when creating a slash command. Same script can serve multiple teams, just keep adding tokens to the array below.
$valid_tokens = array(
"123asdzxcvasdfasdwasdfas", // key 1
"234xdfqadfsdfasdfasfasdf" // key 2
);
if (!in_array($_REQUEST['token'], $valid_tokens)) {
bot_respond(":no_good: *Unauthorized token!* Feel free to grab a copy of this script and host it yourself.");
@PurpleBooth
PurpleBooth / README-Template.md
Last active May 6, 2024 07:22
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@altrive
altrive / Test-RebootRequired.ps1
Last active August 3, 2023 14:34
Check pending reboot on local computer
#Based on <http://gallery.technet.microsoft.com/scriptcenter/Get-PendingReboot-Query-bdb79542>
function Test-RebootRequired
{
$result = @{
CBSRebootPending =$false
WindowsUpdateRebootRequired = $false
FileRenamePending = $false
SCCMRebootPending = $false
}