Skip to content

Instantly share code, notes, and snippets.

Avatar

Mikko Ahlroth Nicd

View GitHub Profile
@Nicd
Nicd / en.ini
Created Sep 11, 2020
Lithium Stats -- This was my most ambitious mIRC script, collecting statistics about your mIRC usage.
View en.ini
[LANG]
langname=English
langby=Nicd
langcomments=The standard english languagefile for Lithium Stats 2.1. © Nicd 2005
disabled=*** Lithium Stats logging disabled.
enabled=*** Lithium Stats logging enabled.
setresetinterval=*** Reset interval set to %lith_resetinterval seconds.
question_setresetinterval=How many seconds between resets?
@Nicd
Nicd / index.html
Last active Feb 9, 2019
lit-element and custom events
View index.html
<!DOCTYPE html>
<html>
<head>
<script type="module" src="ts-out/main.js"></script>
<title>Tilastokeskus</title>
</head>
<body>
<main-index></main-index>
@Nicd
Nicd / index.bs.js
Created Aug 22, 2018
My first BuckleScript thingie
View index.bs.js
// Generated by BUCKLESCRIPT VERSION 4.0.5, PLEASE EDIT WITH CARE
'use strict';
var Old_hash_redirector = require("./old_hash_redirector.bs.js");
var change_url = function (new_url){window.location.href = new_url};
function run() {
return change_url(Old_hash_redirector.run_hash_check(window.location.hash));
}
@Nicd
Nicd / 1_README.md
Created Oct 16, 2017
Proposal for Code::Stats profile API request format
View 1_README.md

Request format

JSON object key is ID that will be returned with the data and value is request specification.

Request specifications

Three keys: target, group and time.

Target means what data should be returned. Can be xp for total XP amounts, language for XP split by language, or machine for XP split by machine.

@Nicd
Nicd / 42.g
Created Sep 8, 2017
GTLT was a 2D Brainfuck-inspired esoteric language I came up with ages ago for fun
View 42.g
EThe answer to life, the
universe and everything
§v >}}++++++++++!{+!v
>+++++]}++++++v>--!Q -
- - ! -
^< ^{++++++<^-------<
View pulse.component.js
import {el} from 'redom';
/**
* Max diameter of pulse circle in pixels
*/
const MAX_SIZE = 20;
/**
* Min diameter of pulse circle in pixels
*/
@Nicd
Nicd / app.tpl.php
Last active Mar 3, 2017
PHP project base with MVT model, simple middleware system, DB basics, router, templates with shared layout
View app.tpl.php
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="Blah blah lorem ipsum.">
<meta name="author" content="Mikko Ahlroth">
<title>My Great Website</title>
@Nicd
Nicd / frontend.build.ex
Last active Jan 18, 2017
Building frontend with Mix Tasks
View frontend.build.ex
defmodule Mix.Tasks.Frontend.Build do
use Mix.Task
import CodeStats.TaskUtils
@shortdoc "Build the frontend"
def run(_) do
run_tasks([
"frontend.build.riot",
"frontend.build.scss"
@Nicd
Nicd / call.sh
Created Dec 31, 2016
Code::Stats profile API suggestion
View call.sh
curl -X GET 'http://localhost:5000/api/users/Nicd'
View codestats.net.service
[Unit]
Description=codestats.net server
After=postgresql.service
[Service]
Type=simple
User=codestats
ExecStart=/var/codestats/codestats/run.sh
WorkingDirectory=/var/codestats/codestats
You can’t perform that action at this time.