Skip to content

Instantly share code, notes, and snippets.

View oscarvarto's full-sized avatar
💭
Coding all the time

Oscar Vargas Torres oscarvarto

💭
Coding all the time
View GitHub Profile
@oscarvarto
oscarvarto / build.gradle
Created April 2, 2025 01:12
Gradle build for a mixed Clojure/Java codebase using lombok and checkerframework
plugins {
id 'com.github.ben-manes.versions' version '0.52.0'
id 'io.freefair.lombok' version '8.12.1'
id 'org.checkerframework' version '0.6.49'
id 'com.diffplug.spotless' version "7.0.2"
id 'dev.clojurephant.clojure' version '0.8.0-beta.7'
id 'application'
}
@oscarvarto
oscarvarto / main.rs
Created September 21, 2024 06:49
Simple command line parser with clap
use clap::Parser;
use std::fmt::Debug;
use std::str::FromStr;
#[derive(Debug, PartialEq, Clone)]
enum Browser {
Chrome,
Firefox,
Edge,
}
@oscarvarto
oscarvarto / Resume.md
Last active September 20, 2024 03:14
Short resume: Oscar Vargas Torres

[Oscar Vargas Torres]

[https://www.linkedin.com/in/oscar-vargas-torres-32145546/] | [https://github.com/oscarvarto] | [https://oscarvarto.mx]

Objective

Software Developer Engineer in Test (experience with Scala, Java and .NET), with professional experience doing high quality translation of technical books/documentation. Previous experience (approx 8 years as a Software Engineer --backend, some mobile and embedded development). Could help testing Ghostty on macOS and Linux, as well as working on documentation and bug reports.

@oscarvarto
oscarvarto / gist:0a4f197c0dbcc37a6f787534bcfa0be5
Created August 28, 2023 17:01
Trying to (mouse) click "Back to index" in Official modules documentation.
Debugger entered--Lisp error: (wrong-type-argument char-or-string-p nil)
insert("[[" nil "]]")
(progn (setq buffer-file-name (buffer-file-name docs-buf)) (let ((org-inhibit-startup t)) (org-mode)) (set (make-local-variable 'org-link-abbrev-alist-local) parent-link-abbrevs) (insert "[[" link "]]") (set-buffer-modified-p nil) (org-link-open (org-element-context)))
(unwind-protect (progn (setq buffer-file-name (buffer-file-name docs-buf)) (let ((org-inhibit-startup t)) (org-mode)) (set (make-local-variable 'org-link-abbrev-alist-local) parent-link-abbrevs) (insert "[[" link "]]") (set-buffer-modified-p nil) (org-link-open (org-element-context))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
(save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (setq buffer-file-name (buffer-file-name docs-buf)) (let ((org-inhibit-startup t)) (org-mode)) (set (make-local-variable 'org-link-abbrev-alist-local) parent-link-abbrevs) (insert "[[" link "]]") (set-buffer-modified-p nil) (org-link-ope
@oscarvarto
oscarvarto / gist:5549cfd777795afd3ef61cd8f7b94ea5
Created August 28, 2023 16:20
Doom Emacs - System Information.
generated Aug 28, 2023 10:15:42
system "Garuda Linux" Linux 6.4.12-zen1-1-zen x86_64 pgtk
emacs 29.1 ~/.config/emacs/
doom 3.0.0-pre PROFILE=_@0 grafted, HEAD -> master, origin/master, origin/HEAD
7a75030 2023-08-21 18:17:05 +0200 ~/.config/doom/
shell /bin/bash
features ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBOTF LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY
PDUMPER PGTK PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF
TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XIM GTK3 ZLIB
@oscarvarto
oscarvarto / cannot-open-doc-el
Created August 28, 2023 16:14
Cannot open documentation Doom Emacs - Cannot find entry with ID
error("Cannot find entry with ID \"%s\"" "46d2058d-249e-45a7-a7a2-58bade48df65")
#<subr org-id-open>("46d2058d-249e-45a7-a7a2-58bade48df65" nil)
funcall(#<subr org-id-open> "46d2058d-249e-45a7-a7a2-58bade48df65" nil)
(prog1 (funcall fn id arg) (cond ((null search)) ((string-match-p "\\`[0-9]+\\'" search) (forward-line (string-to-number option))) ((string-match "^/\\([^/]+\\)/$" search) (let ((match (match-string 1 search))) (save-excursion (org-link-search search)) (if (re-search-forward match) (progn (goto-char (match-beginning 0)))))) ((org-link-search search))))
(progn (if --cl-rest-- (signal 'wrong-number-of-arguments (list '(id &optional search) (+ 2 (length --cl-rest--))))) (prog1 (funcall fn id arg) (cond ((null search)) ((string-match-p "\\`[0-9]+\\'" search) (forward-line (string-to-number option))) ((string-match "^/\\([^/]+\\)/$" search) (let ((match (match-string 1 search))) (save-excursion (org-link-search search)) (if (re-search-forward match) (progn (goto-char ...))))) ((org-link-search
@oscarvarto
oscarvarto / gist:204e9ce6244435bb725066b529644698
Created July 28, 2020 03:30
Output/log error message after opening haskell-language-server repo with VSCode
Starting GHCi with: "stack --no-terminal --color never repl --no-load ghcide:lib ghcide:exe:ghcide ghcide:exe:ghcide-bench ghcide:exe:ghcide-test-preprocessor ghcide:test:ghcide-tests ghcide:bench:benchHist haskell-language-server:lib haskell-language-server:exe:haskell-language-server haskell-language-server:exe:haskell-language-server-wrapper haskell-language-server:test:func-test haskell-language-server:test:wrapper-test"
(Under cwd /home/oscarvarto/gitRepos/haskell-language-server)
-> :set prompt ""
|> :set prompt-cont ""
ghci |
ghci | * * * * * * * *
ghci | Warning: There are cabal settings for this project which may prevent GHCi from loading your code properly.
ghci | In some cases it can also load some projects which would otherwise fail to build.
ghci |
ghci | -XOverloadedStrings will be used, but it can cause type ambiguity in code not usually compiled with it.
@oscarvarto
oscarvarto / gist:f294ff96432ba70b0c2f46dc2f8f2ea1
Created July 12, 2020 02:39
Error while running `cabal install` in docopt.hs' examples directory
NavalFate/Main.hs:7:18: error:
• Exception when trying to run compile-time code:
NavalFate/USAGE.docopt: openFile: does not exist (No such file or directory)
Code: template-haskell-2.14.0.0:Language.Haskell.TH.Quote.quoteExp
docoptFile "NavalFate/USAGE.docopt"
• In the quasi-quotation: [docoptFile|NavalFate/USAGE.docopt|]
|
7 | navalFateUsage = [docoptFile|NavalFate/USAGE.docopt|]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
$ stack build
Building all executables for `my-projext' once. After a successful build of all of them, only specified executables will be rebuilt.
my-projext> configure (lib + exe)
/home/oscarvarto/.stack/setup-exe-cache/x86_64-linux-nix/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.5: error while loading shared libraries: libffi.so.6: cannot open shared object file: No such file or directory
-- While building package my-projext-0.1.0.0 using:
/home/oscarvarto/.stack/setup-exe-cache/x86_64-linux-nix/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.5 --builddir=.stack-work/dist/x86_64-linux-nix/Cabal-2.4.0.1 configure --user --package-db=clear --package-db=global --package-db=/home/oscarvarto/.stack/snapshots/x86_64-linux-nix/627d44f0e613b0677d8e0a330cc3a37ff543ad785d74f7e3e2145edd946c4499/8.6.5/pkgdb --package-db=/home/oscarvarto/haskellDev/my-projext/.stack-work/install/x86_64-linux-nix/627d44f0e613b0677d8e0a330cc3a37ff543ad785d74f7e3e2145edd946c4499/8.6.5/pkgdb --libdir=/home/oscarvarto/haskellDev/my-projext/.stack-wo
Got error while processing diagnostics: readCreateProcess: /nix/store/36al53k8r3ddqj1bz1kawxa3f3cdkilj-cabal-helper-0.9.0.0/bin/cabal-helper-wrapper "--with-ghc=ghc" "--with-ghc-pkg=ghc-pkg" "--with-cabal=cabal" "v1-style" "/home/oscarvarto/haskellDev/my-projext" "/home/oscarvarto/haskellDev/my-projext/dist" "package-db-stack" "flags" "compiler-version" "ghc-merged-pkg-options" "config-flags" "non-default-config-flags" "ghc-src-options" "ghc-pkg-options" "ghc-lang-options" "ghc-options" "source-dirs" "entrypoints" "needs-build-output" (exit 1): failed