Skip to content

Instantly share code, notes, and snippets.

Valentin Funk Kamshak

Block or report user

Report or block Kamshak

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@Kamshak
Kamshak / no_selection.lua
Last active Sep 28, 2015
Put this into a new file in lua/autorun/no_model_selection.lua to disable sandbox player selection
View no_selection.lua
AddCSLuaFile()
hook.Add( "InitPostEntity", "RemoveEditor", function( )
list.Set( "DesktopWindows", "PlayerEditor", {
title = "Player Model",
icon = "icon64/playermodel.png",
width = 250,
height = 50,
onewindow = true,
@Kamshak
Kamshak / provision-node-kubernetes-ubuntu
Last active Apr 15, 2016
Some instructions for adding a new node to the cluster using the ubuntu scripts
View provision-node-kubernetes-ubuntu
export nodes="root@<MASTER NODE> root@<NEW NODE>"
export role="ai i"
export NUM_NODES=${NUM_NODES:-2}
export SERVICE_CLUSTER_IP_RANGE=192.168.3.0/24
export FLANNEL_NET=172.16.0.0/16
./new-node.sh
<IN kubernetes/cluster/new-node.sh>
#!/bin/bash
@Kamshak
Kamshak / custom-router.js
Last active Oct 5, 2016
ui-router-custom.js
View custom-router.js
/*!
* State-based routing for AngularJS
* @version v1.0.0-beta.3
* @link https://ui-router.github.io
* @license MIT License, http://www.opensource.org/licenses/MIT
*/
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory(require("angular"));
else if(typeof define === 'function' && define.amd)
View battlefield1_ida.py
# Creates Structures TypeInfo / TypeInfoData
def initStructures():
strucId = GetStrucIdByName("TypeInfo")
if (strucId == BADADDR):
strucIdInfoData = AddStrucEx(-1, "TypeInfoData", 0)
AddStrucMember(strucIdInfoData, "m_name", -1, (FF_QWRD|FF_DATA|FF_0CHAR), ASCSTR_C, 8)
ApplyType(GetMemberId(strucIdInfoData, 0), ParseType("char*", 0))
strucId = AddStrucEx(-1, "TypeInfo", 0)
AddStrucMember(strucId, "m_infoData", -1, (FF_QWRD|FF_DATA|FF_0STRO), 0, 8)
View gist.md

Hi,

thanks for the speedy response. The devtool setting is set to hidden-source-map. I've just skimmed the plugin's source code and it does not set any header. Does that mean that when uploading a sourcemap without a comment reference in the minified file i need to set a HTTP header when uploading?

I've tried reading the CLI's source for some information and it seems that a x-sourcemap header is set. (Unfortunately https://docs.sentry.io/api/releases/post-release-files/ does not provide any information on this). I'll make a pull request for the webpack plugin to include that header if this is the case.

What format should the header value have? E.g. I have a file index.bundle.js and index.bundle.js.map, do i set it to ~/index.bundle.js?

View gist:156ec1c39419b8cc2047efe1513d207d
// ==UserScript==
// @name ɮuy shit faster
// @namespace http://tampermonkey.net/
// @version 0.1
// @description ๖ۣɮuy shit faster
// @author VALLUS
// @include http://agariohub.net/client/shop
// @grant none
// ==/UserScript==
@Kamshak
Kamshak / print.lua
Last active Jun 27, 2017
Example for Pointshop2.com Drops and Crates custom lua crate and function to print all item class names.
View print.lua
local str = LibK._(Pointshop2.GetRegisteredItems()):chain()
:map(function(item)
return { className = item.className, name = item:GetPrintName() }
end)
:sort(function(a, b)
if tonumber(a.className) and tonumber(b.className) then
return tonumber(a.className) < tonumber(b.className)
elseif tonumber(a) and not tonumber(b) then
return false
else
@Kamshak
Kamshak / random.lua
Last active Jun 28, 2017
Give a random item from category
View random.lua
local function GiveRandomItemFromCategory( ply, categoryName )
local factory = Pointshop2.ItemFromCategoryFactory:new()
factory.settings = {
["ManualSettings.CategoryName"] = categoryName,
["BasicSettings.WeightedRandom"] = true
}
local item = factory:CreateItem( true )
return ply:PS2_EasyAddItem( item.class.className )
end
@Kamshak
Kamshak / leaveSessionTracker.js
Last active Jul 3, 2017
Sends events to analytics in timeouts to improve session tracking
View leaveSessionTracker.js
window.addEventListener('beforeunload',
function(){
ga('send', 'event', 'Website', 'Unload', {transport: 'beacon', nonInteraction:true});
}
);
var timeout = 1;
var startTime = new Date().getTime();
function startBeacon() {
var timeOnSite = (startTime - new Date().getTime()) / 1000;
@Kamshak
Kamshak / sh_jumppack.lua
Last active Jul 14, 2017
Jump Pack higher Jumps
View sh_jumppack.lua
ITEM.baseClass = "base_hat"
ITEM.PrintName = "Jump Pack"
ITEM.Description = "Makes you jump higher!"
ITEM.Price = {
points = 1000,
}
ITEM.static.validSlots = {
"Accessory",
}
You can’t perform that action at this time.