Skip to content

Instantly share code, notes, and snippets.

View afkcodes's full-sized avatar
💭
afk

Ashish Kumar afkcodes

💭
afk
View GitHub Profile
@afkcodes
afkcodes / letsencrypt_create.sh
Created July 2, 2023 11:06 — forked from ervilis/letsencrypt_create.sh
Script to generate LetsEncrypt certificate
#!/bin/sh
#
# Wrapper script for the letsencrypt client to generate a server certificate in
# manual mode. It uses openssl to generate the key and should not modify the
# server configuration. It can be called off-side, i.e. not on the destination
# server.
#
# usage: letsencrypt_create.sh DOMAIN [DOMAIN...]
set -e
@afkcodes
afkcodes / squircle.dart
Created May 8, 2023 05:58 — forked from slightfoot/squircle.dart
Flutter Squircle Shape
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return new MaterialApp(
title: 'Squircle',
home: new Scaffold(
@afkcodes
afkcodes / dataMiner.js
Created January 5, 2022 07:41 — forked from Harshmakadia/dataMiner.js
twitter-analytics-data-scraper
// 1. Go to https://analytics.twitter.com/
// 2. Keep scrolling till the end until all the stats data is loaded
// 3. Right click on the page click on last option "Inspect" a window should open select console from that
// 4. copy this entire function
function getVal (val) {
val=val.replace(/\,/g,'');
@afkcodes
afkcodes / .eslintrc.json
Created November 11, 2021 12:22 — forked from Halaumo/.eslintrc.json
eslint
// eslint-react
{
"root": true,
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 2021,
"sourceType": "module",
"project": "./tsconfig.json",
"tsconfigRootDir": ".",
// "warnOnUnsupportedTypeScriptVersion": "false",
@afkcodes
afkcodes / dart.json
Created October 9, 2021 10:28 — forked from arifikhsan/dart.json
snippet from resocoder
{
"Part statement": {
"prefix": "pts",
"body": [
"part '${TM_FILENAME_BASE}.g.dart';",
],
"description": "Creates a filled-in part statement"
},
"Part 'Freezed' statement": {
"prefix": "ptf",
@afkcodes
afkcodes / kitty.conf
Created July 12, 2021 03:56 — forked from nicbet/kitty.conf
Kitty Terminal Configuration
# /.config/kitty/kitty.conf
# vim:fileencoding=utf-8:ft=conf:foldmethod=marker
#: Fonts {{{
#: kitty has very powerful font management. You can configure
#: individual font faces and even specify special fonts for particular
#: characters.
@afkcodes
afkcodes / kitty.conf
Created July 12, 2021 03:02 — forked from ggsalas/kitty.conf
Kitty terminal - one dark theme [~/.config/kitty/kitty.conf]
# vim:fileencoding=utf-8:ft=conf:foldmethod=marker
#: Fonts {{{
#: kitty has very powerful font management. You can configure
#: individual font faces and even specify special fonts for particular
#: characters.
# font_family Monaco
font_family Source Code Pro
@afkcodes
afkcodes / eslint_prettier_airbnb.md
Created November 29, 2020 17:04 — forked from bradtraversy/eslint_prettier_airbnb.md
ESLint, Prettier & Airbnb Setup

VSCode - ESLint, Prettier & Airbnb Setup

1. Install ESLint & Prettier extensions for VSCode

Optional - Set format on save and any global prettier options

2. Install Packages

npm i -D eslint prettier eslint-plugin-prettier eslint-config-prettier eslint-plugin-node eslint-config-node