Skip to content

Instantly share code, notes, and snippets.

View MaurizioCasciano's full-sized avatar
👨‍💻
Turning Bits ON & OFF

Maurizio Casciano MaurizioCasciano

👨‍💻
Turning Bits ON & OFF
View GitHub Profile
@willccbb
willccbb / grpo_demo.py
Last active July 15, 2025 01:48
GRPO Llama-1B
# train_grpo.py
#
# See https://github.com/willccbb/verifiers for ongoing developments
#
"""
citation:
@misc{brown2025grpodemo,
title={Granular Format Rewards for Eliciting Mathematical Reasoning Capabilities in Small Language Models},
author={Brown, William},
@javabrett
javabrett / Dockerfile
Created October 18, 2020 11:00
Build kafkacat on Centos 8
FROM centos:centos8.2.2004
RUN yum update -y && \
yum group install -y "Development Tools" && \
yum install -y git cyrus-sasl-devel cmake libcurl-devel
RUN git clone https://github.com/edenhill/kafkacat.git && \
cd kafkacat/ && \
./bootstrap.sh && \
./kafkacat -h
@markasoftware
markasoftware / enterprise_token.rb
Last active July 11, 2025 12:22
OpenProject Enterprise mode for free
############ If you are using DOCKER all-in-one image, create Dockerfile like: ################
############ FROM openproject/openproject:16 ################
############ COPY ./enterprise_token.rb app/models/enterprise_token.rb ################
############ If you are runing a manual installation: ################
############ REPLACE app/models/enterprise_token.rb in the source code with this file! ################
############ also be sure to RESTART OpenProject after replacing the file. ################
############ If using some other set up (eg docker-compose), read the comments on ################
############ https://gist.github.com/markasoftware/f5b2e55a2c2e3abb1f9eefcdf0bfff45 ################
@simonwep
simonwep / blockadblock-blocker.tapermonkey.js
Last active September 30, 2023 14:32
Blocks BlockAdBlock scripts
// ==UserScript==
// @name BlockAdblock Blocker
// @version 1.0
// @namespace http://tampermonkey.net/
// @description Blocks block-adblock
// @match *://**/*
// @grant none
// @run-at document-start
// ==/UserScript==
@abdallahokasha
abdallahokasha / Install Rails on Ubuntu.md
Last active November 12, 2022 20:47
How to install Rails and RVM on Ubuntu

Install rvm

sudo apt-get install software-properties-common

  1. Add the PPA and install the package

Open a terminal (Ctrl+Alt+T) and run:

sudo apt-add-repository -y ppa:rael-gc/rvm
@dogeared
dogeared / SpringBoot15Application.java
Last active July 7, 2020 09:33
spring boot 1.5.x with spring security 4 vs. spring boot 2.1.3 with spring security 5
@EnableOAuth2Sso
@RestController
@SpringBootApplication
public class OAuth2DemoApplication_1_5 {
@Value("#{ @environment['security.oauth2.resource.server'] }")
private String resourceServerUrl;
private OAuth2ProtectedResourceDetails resource;
@GhostofGoes
GhostofGoes / mac_addrs.py
Last active May 5, 2025 21:58
Get MAC addresses using a variety of Python packages.
# **************************************
# ** Get MAC address of a remote host **
def arpreq_ip(ip):
# type: (str) -> Optional[str]
import arpreq
return arpreq.arpreq('192.168.1.1')
def scapy_ip(ip):
# type: (str) -> str
"""Requires root permissions on POSIX platforms.
@bmaupin
bmaupin / open-source-sso.md
Last active June 15, 2025 20:59
Comparison of some open-source SSO implementations

⚠️ This is not maintained. Feel free to check comments and/or forks for more current options.

Background

This was created years ago; at the time I'd been a Shibboleth admin for nearly a decade but we needed something that could handle OIDC/OAuth and that explicitly supported OpenJDK. After a lot of investigation, I really liked Keycloak/Red Hat Single Sign-On. More details here: Gluu vs keycloack vs wso2 identity management

Comparison

(Items in bold indicate possible concerns)

@briandominick
briandominick / asciidoc-static.adoc
Last active June 16, 2025 16:12
Static Site Generators with AsciiDoc Support

There are 28 static site generators that support AsciiDoc sourcing.

#!/bin/bash
KC_REALM=<insert realm name here>
KC_USERNAME=<username here>
KC_PASSWORD=<password here>
KC_CLIENT=<client name here>
KC_CLIENT_SECRET=<client secret here>
KC_SERVER=<server address and port here>
KC_CONTEXT=auth