Skip to content

Instantly share code, notes, and snippets.

View shubhamkumar13's full-sized avatar
😑
is existing

shubham shubhamkumar13

😑
is existing
View GitHub Profile

Error log

[  4%] Building C object lib/libappimage/src/libappimage_hashlib/CMakeFiles/libappimage_hashlib.dir/md5.c.o
[  4%] Linking C static library libappimage_hashlib.a
[  4%] Built target libappimage_hashlib
[  4%] Creating directories for 'xz-EXTERNAL'
[  8%] Performing download step (download, verify and extract) for 'xz-EXTERNAL'
-- verifying file...
       file='/home/sk/AppImageLauncher/build/lib/libappimage/xz-EXTERNAL-prefix/src/xz-5.2.3.tar.gz'
-- File already exists and hash match (skip download):
@shubhamkumar13
shubhamkumar13 / ocaml_retreat.md
Last active March 22, 2024 07:25
what I did in ocaml retreat

Motive

From the Hackacamel list I picked up working on the cdf plotter using TUI. Now I have never developed TUIs or GUIs so I thought this would be the perfect thing to do.

The initial hurdle was choosing the library, I wanted to try use OCaml 5 so I chose Minttea which is TUI framework inspired by Bubble Tea implemented in Golang and uses the The elm architecture (The TEA in minttea).

Biggest Hurdles

@shubhamkumar13
shubhamkumar13 / to_path.ml
Created February 14, 2024 09:04
convert a string to Eio.Path.t
let to_path ~env path = Eio.Stdenv.fs env / path
@shubhamkumar13
shubhamkumar13 / run_ls.ml
Created February 13, 2024 10:15
run a unix command
let _ =
Eio_main.run (fun env ->
let process_manager = Eio.Stdenv.process_mgr env in
Eio.Process.parse_out process_manager Eio.Buf_read.take_all ["ls"])
@shubhamkumar13
shubhamkumar13 / test_lpm.ml
Last active August 1, 2023 14:34
testing lpm by comparing outputs with generated tz files
module Fpath = Fpath
module OS = Bos.OS
module Cmd = Bos.Cmd
open Core
let ( let* ) o f = Result.bind o ~f
let get_tmp_dir () : string = OS.Dir.default_tmp () |> Fpath.to_string
let rm_rf ~(path : string) : unit =
OS.Dir.delete ~must_exist:true ~recurse:true (Fpath.v path) |> function
@shubhamkumar13
shubhamkumar13 / pattern-maching.purs
Created July 20, 2023 09:25
recipe for pattern matching arrays in purescript
f l = case Array.uncons l of
Just {head,tail} -> handle non null case
Nothing -> handle null case
@shubhamkumar13
shubhamkumar13 / bash_test.bash
Created July 17, 2023 11:27
test file for ligo package manager
function github_ssh() {
echo "git@github.com:ligolang/$1.git"
}
function dir() {
echo "$HOME/nuke/test_lpm/$1"
}
DAO_JSLIGO=dao-jsligo
DAO_CAMELIGO=dao-cameligo
@shubhamkumar13
shubhamkumar13 / result.txt
Created July 17, 2023 11:25
the result of tests
Cloning into '/home/sk/nuke/test_lpm/dao-jsligo'...
Cloning into '/home/sk/nuke/test_lpm/dao-cameligo'...
Cloning into '/home/sk/nuke/test_lpm/permit-jsligo'...
Cloning into '/home/sk/nuke/test_lpm/permit-cameligo'...
{ parameter
(or (pair %propose (string %descriptionLink) (option %hash bytes))
(or (option %cancel nat)
(or (nat %lock)
(or (nat %release)
@shubhamkumar13
shubhamkumar13 / remove_esy.ml
Last active June 7, 2023 11:43
a sample code which is on the path to remove esy
module Cohttp_lwt_unix = Cohttp_lwt_unix
module Json = Yojson.Basic
module Cohttp_lwt = Cohttp_lwt
open Lwt.Syntax
open Lwt.Infix
let ( // ) a b = a ^ "/" ^ b
let ligo_package_dir = "." // ".ligo" // "source" // "i"
let baseurl = "https://packages.ligolang.org/-/api/@ligo"
let toplevel_packages = [ ("permit", "1.0.0"); ("fa", "1.0.0") ]
@shubhamkumar13
shubhamkumar13 / notes.md
Created June 1, 2023 08:04
From a beginners perspective
  1. Startup should be before Install taq plugins

    • makes it less confusing for beginners who might get an error This doesn't appear to be a taqueria project. and get stuck.
    • also in the command add a mkdir <insert-dir-name> for a root directory so that they know not to install it in their $HOME or any global scope just as an extra piece of caution
  2. Initialize/create's root directory should be specified helps in understanding where the contract would be created using taq create ... command.

    • maybe let users know it's a template for a counter, helpful context but it's optional.
    • do update the code since it is different from the template generated
        cat intezos.jsligo