Skip to content

Instantly share code, notes, and snippets.

View drupol's full-sized avatar

Pol Dellaiera drupol

View GitHub Profile
@drupol
drupol / overlay.nix
Last active June 26, 2024 03:17
OpenBlas overlay
(self: super: {
openblas = super.openblas.overrideAttrs (oldAttrs: {
makeFlags = oldAttrs.makeFlags ++ [
"DEBUG=1"
];
});
})
@drupol
drupol / .devcontainer.json
Created April 10, 2024 11:26
.devcontainer.json
{
"image": "mcr.microsoft.com/devcontainers/base:alpine",
"features": {
"ghcr.io/devcontainers/features/nix:1": {
"extraNixConfig": "experimental-features = nix-command flakes"
}
},
"onCreateCommand": "nix run home-manager/master -- init --switch && rm -rf ~/.config/git/config && nix shell nixpkgs#git -c nix run home-manager/master -- switch --flake git+https://code.europa.eu/ecphp/devs-profile#light --impure",
"customizations": {
"vscode": {
@drupol
drupol / postgres.nix
Created April 2, 2024 12:24
postgres.nix
{ lib
, dockerTools
, writeText
, writeShellScriptBin
, postgresql
, bash
, coreutils
, nss_wrapper
}:
@drupol
drupol / flake.nix
Created March 22, 2024 10:36
flake.nix
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
systems.url = "github:nix-systems/default";
};
outputs = inputs @ { self, flake-parts, ... }: flake-parts.lib.mkFlake { inherit inputs; } {
systems = import inputs.systems;
perSystem = { config, self', inputs', pkgs, system, lib, ... }: let
@drupol
drupol / typst-preview.log
Created March 18, 2024 15:41
typst-preview.log
typst-preview> Compiling typst-ts-compiler v0.4.2-rc9
typst-preview> Compiling await-tree v0.1.2
typst-preview> Compiling futures v0.3.30
typst-preview> warning: typst-preview@0.11.1: could not find repository at '/build/source'; class=Repository (6); code=NotFound (-3)
typst-preview> warning: typst-preview@0.11.1: VERGEN_GIT_DESCRIBE set to default
typst-preview> warning: typst-preview@0.11.1: VERGEN_GIT_SHA set to default
typst-preview> Compiling open v5.1.2
typst-preview> Compiling tokio-tungstenite v0.21.0
typst-preview> error: couldn't read src/index.html: No such file or directory (os error 2)
typst-preview> --> src/lib.rs:116:20
@drupol
drupol / guix.scm
Created March 18, 2024 12:42
guix.scm
(use-modules (guix)
(guix build-system gnu))
(define-public datetime
(package
(name "datetime")
(version "1.0")
(source (local-file "./src" #:recursive? #t))
(build-system gnu-build-system)
(arguments
@drupol
drupol / CITATION.cff
Created March 12, 2024 08:07
CITATION.cff
# This CITATION.cff file was generated with cffinit.
# Visit https://bit.ly/cffinit to generate yours today!
cff-version: 1.2.0
title: Reproducible Builds
message: >-
If you use this software, please cite it using the
metadata from this file.
type: software
authors:
@drupol
drupol / php-ec.patch
Created February 18, 2024 09:57
php-ec.patch
diff --git i/ext/standard/css.c w/ext/standard/css.c
index 9009d95291..bb4a95c3c8 100644
--- i/ext/standard/css.c
+++ w/ext/standard/css.c
@@ -32,8 +32,8 @@ PHPAPI ZEND_COLD void php_info_print_css(void) /* {{{ */
PUTS("h1 {font-size: 150%;}\n");
PUTS("h2 {font-size: 125%;}\n");
PUTS(".p {text-align: left;}\n");
- PUTS(".e {background-color: #ccf; width: 300px; font-weight: bold;}\n");
- PUTS(".h {background-color: #99c; font-weight: bold;}\n");
@drupol
drupol / 0001-reproducibility-patch.patch
Last active February 15, 2024 11:20
box-project/box reproducible PHAR poc
From b91328c0cce43b0e9fe9b1841953813f04bfa88d Mon Sep 17 00:00:00 2001
From: Pol Dellaiera <pol.dellaiera@protonmail.com>
Date: Thu, 15 Feb 2024 12:02:02 +0100
Subject: [PATCH] reproducibility patch
---
box.json.dist | 9 ++++++---
scoper.inc.php | 1 +
2 files changed, 7 insertions(+), 3 deletions(-)
{
"name": "foo/bar",
"type": "library",
"description": "description",
"license": "MIT",
"require": {
"php": "^7.2.5 || ^8.0",
"composer/ca-bundle": "^1.0"
}
}