Skip to content

Instantly share code, notes, and snippets.

View kdabir's full-sized avatar
👨‍💻
go git it

Kunal Dabir kdabir

👨‍💻
go git it
View GitHub Profile
// unofficial sqlite3 types.
// These are typed only for my scope
declare module "@sqlite.org/sqlite-wasm" {
type InitOptions = {
print: (...msg: any[]) => void;
printErr: (...msg: any[]) => void;
};
declare type PreparedStatement = {
@tomsing1
tomsing1 / json_in_sqlite.qmd
Created December 31, 2022 22:50
Experimenting with JSON fields in a SQLite database
---
title: "Experimenting with SQLite"
editor_options:
chunk_output_type: inline
---
```{r}
library(glue)
library(RSQLite)
library(jsonlite)
@asardaes
asardaes / README.txt
Last active April 15, 2023 12:33
Publishing a Gradle precompiled script plugin to a custom repository
Gradle plugins require a marker:
https://docs.gradle.org/current/userguide/plugins.html#sec:plugin_markers
Markers aren't published for precompiled scripts using groovy-gradle-plugin :(
https://github.com/gradle/gradle/issues/15190
The plugin_marker module creates the marker that Gradle needs to find the plugin and also publishes it,
see https://stackoverflow.com/a/60798021/5793905
Assuming all gradle modules have the same group with a folder structure like:
@danteese
danteese / code.gs
Created July 27, 2020 05:24
Introduction to Google Form Mapping
/**
* Map function to get all the results from the database
* this is specially useful if you're trying to access to
* the questions and options as you may want to generate
* a report in your system...(not only the answers)
*
* I mainly did this because of the lack of good examples
* on the documentation, only through other github projects
* and try and failure.
*

Module Workers Polyfill npm version

This is a 1.1kb polyfill for Module Workers.

It adds support for new Worker('..',{type:'module'}) to all modern browsers (those that support fetch).

Usage

Copy module-workers-polyfill.js to your web directory, then load it using an import or a script tag. It just needs to be loaded before instantiating your Worker.

@sualeh
sualeh / how_to_sign_and_release_to_the_central_repository_with_github_actions.md
Last active October 30, 2024 15:57
How to Sign and Release to The Central Repository with GitHub Actions

How to Sign and Release to The Central Repository with GitHub Actions

GitHub allows automated builds using GitHub Actions. A commonly asked question is how to release artifacts (packaged Java jars) built by Maven and Gradle to The Central Repository. The GitHub Actions documentation provides only part of the answer.

So, first, configure your Maven project for staging artifacts to The Central Repository, by reading through Configuring Your Project for Deployment and following those steps. Please make sure that the maven-gpg-plugin is configured to prevent gpg from using PIN entry programs, as follows:

<configuration>
  <gpgArguments>
      <arg>--pinentry-mode</arg>
 loopback
@jimit24365
jimit24365 / Guide
Last active March 5, 2020 04:32
Production Ready App in Flutter
Wifi SSID - Technogise_2.4 (mobile) and Technogise_5 (Laptops) Password is 62697514
PRE-REQUISITES:
Get your laptops with the following INSTALLATIONS done:
• Flutter - https://flutter.dev/docs/get-started/install
• Android Studio - https://developer.android.com/studio/install
• Plugins - https://flutter.dev/docs/get-started/editor
MaterialApp
https://dartpad.dev/02b1e191976afffb242e15c8da240ffc
Introduction
============
Industry statistics as a whole have failed to improve much since 1968, when software engineering and
scientific management were introduced as means for resolving the "software crisis". Unfortunately
abandoned projects, cost/time overruns, and bloated, buggy software still dominate the landscape.
In spite of the efforts to mitigate this situation --like XP, agile, software craftsmanship or DDD-- the
reality is that a usual software project stack involves an increasingly larger number of programming
languages, DSLs, frameworks, systems, tools, techniques and processes, so it is a fact that the
@WesThorburn
WesThorburn / adding_wasm_MIME.md
Last active July 30, 2023 04:35
Webassembly, wasm files, webservers and MIME types

When compiling client files to webassembly, usually you'll end up with both .js and .wasm files. By default, most webservers don't know about the wasm MIME type. You'll likely see the following error: wasm streaming compile failed: TypeError: Failed to execute 'compile' on 'WebAssembly': Incorrect response MIME type. Expected 'application/wasm'.

Here is how to add the wasm MIME type (on linux systems, apache + nginx):

Open /etc/mime.types You'll see two columns, media type on the left, file type on the right Add the line application/wasm wasm

@sconstantinides
sconstantinides / App.js
Created May 1, 2018 23:37
Sample Firebase task app
import React, { Component } from 'react';
import firebase from '@firebase/app';
import firestore from './firestore'; // Code: https://gist.github.com/sconstantinides/546a48ba183b1234f750ca6261440199
class App extends Component {
constructor(props) {
super(props);
this.state = {
userId: localStorage.getItem('userId') || '',