Skip to content

Instantly share code, notes, and snippets.

View marcusramberg's full-sized avatar

Marcus Ramberg marcusramberg

View GitHub Profile
diff --git a/pkgs/development/interpreters/perl/interpreter.nix b/pkgs/development/interpreters/perl/interpreter.nix
index 0275423cb08e..ecdcae7f32d9 100644
--- a/pkgs/development/interpreters/perl/interpreter.nix
+++ b/pkgs/development/interpreters/perl/interpreter.nix
@@ -103,6 +103,7 @@ stdenv.mkDerivation (rec {
"-Dlibpth=\"\""
"-Dglibpth=\"\""
"-Ddefault_inc_excludes_dot"
+ "${if stdenv.targetPlatform.isBigEndian then ''-Dbyteorder=4321'' else ''-Dbyteorder=1234''}"
]
diff --git a/pkgs/applications/editors/vim/macvim.nix b/pkgs/applications/editors/vim/macvim.nix
index bf2fb1fb02f7..b30fb0dac7b1 100644
--- a/pkgs/applications/editors/vim/macvim.nix
+++ b/pkgs/applications/editors/vim/macvim.nix
@@ -8,7 +8,7 @@
, cscope
, ruby_3_2
, tcl
-, perl536
+, perl540
diff --git a/lib/Encode/IMAPUTF7.pm b/lib/Encode/IMAPUTF7.pm
index 07835b9..411c57f 100644
--- a/lib/Encode/IMAPUTF7.pm
+++ b/lib/Encode/IMAPUTF7.pm
@@ -9,6 +9,8 @@ __PACKAGE__->Define('IMAP-UTF-7', 'imap-utf-7');
our $VERSION = '1.05';
use MIME::Base64;
use Encode;
+use Exporter 'import';
+our @EXPORT_OK = qw(encode decode);
error:
… while calling the 'derivationStrict' builtin
at <nix/derivation-internal.nix>:9:12:
8|
9| strict = derivationStrict drvAttrs;
| ^
10|
… while evaluating derivation 'nix-static-x86_64-unknown-linux-musl-2.18.5'
whose name attribute is located at /nix/store/kjf402kxck2ia9nbx07v8b80840i8qq2-bcghcr9qwqmanpds017w75mcqda4fgab-source/pkgs/stdenv/generic/make-derivation.nix:334:7
---
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
default_install_hook_types: [pre-commit, commit-msg]
repos:
- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.28.1
hooks:
- id: check-github-workflows
- id: check-renovate
with import <nixpkgs> { };
with builtins;
rec {
yaml2nix = path:
let
jsonOutputDrv =
runCommand "from-yaml" { nativeBuildInputs = [ remarshal ]; }
''remarshal -if yaml -i "${path}" -of json -o "$out"'';
in fromJSON (readFile jsonOutputDrv);
import std/[strutils, sequtils, tables]
type NumItem = object
num: string
start: (int, int)
var
symbolTable = initTable[(int, int), char]()
foundNums = newSeq[NumItem](0)
sum: int
sum2: int
for i, line in toSeq("input".lines):
#!/usr/bin/perl
use strict;
my $sum=0;
while (my $round = <>) {
my ($game, $games) = split /:/, $round;
my ($id) = $game =~ /(\d+)$/;
my $toobig=0;
print $games;
my %seen;
foreach my $game (split /;/, $games) {
const std = @import("std");
const MatchError = error{NoMatch};
pub fn main() !void {
const allocator = std.heap.page_allocator;
const stdin_file = std.io.getStdIn().reader();
var br = std.io.bufferedReader(stdin_file);
const stdin = br.reader();
const std = @import("std");
const MatchError = error{ PartialMatch, NoMatch };
pub fn main() !void {
const allocator = std.heap.page_allocator;
// stdout is for the actual output of your application, for example if you
// are implementing gzip, then only the compressed bytes should be sent to
// stdout, not any debugging messages.