Skip to content

Instantly share code, notes, and snippets.

View tolumide-ng's full-sized avatar

Tolumide Shopein tolumide-ng

  • Ex-Andela
  • Berlin, Germany
  • 09:22 (UTC -12:00)
View GitHub Profile
@lancejpollard
lancejpollard / meta-tags.md
Created March 5, 2012 13:54
Complete List of HTML Meta Tags

Copied from http://code.lancepollard.com/complete-list-of-html-meta-tags/

Basic HTML Meta Tags

<meta name="keywords" content="your, tags"/>
<meta name="description" content="150 words"/>
<meta name="subject" content="your website's subject">
<meta name="copyright"content="company name">
<meta name="language" content="ES">
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active July 22, 2024 18:26
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@danieliser
danieliser / es5.js
Last active February 27, 2024 23:11
Convert Hex Color to rgba with opacity
/**
* ECMA2015
*/
function convertHex(hexCode, opacity = 1){
var hex = hexCode.replace('#', '');
if (hex.length === 3) {
hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
}
@anthonyclays
anthonyclays / perfect_squares.rs
Created September 14, 2015 08:37
Fast perfect square test in Rust
fn isqrt(n: usize) -> usize {
n == 0 && return n;
let mut s = (n as f64).sqrt() as usize;
s = (s + n / s) >> 1;
if s * s > n { s - 1 } else { s }
}
fn perfect_sqrt(n: usize) -> isize {
match n & 0xf {
0 | 1 | 4 | 9 => {
@lopspower
lopspower / README.md
Last active July 20, 2024 20:26
Hexadecimal color code for transparency

Hexadecimal color code for transparency

Twitter

How to set transparency with hex value ?

For example, you want to set 40% alpha transparence to #000000 (black color), you need to add 66 like this #66000000.

Download This sample on Google Play Store

@tomysmile
tomysmile / mac-setup-redis.md
Last active July 16, 2024 04:45
Brew install Redis on Mac

type below:

brew update
brew install redis

To have launchd start redis now and restart at login:

brew services start redis
@kestein
kestein / Private_Crates.md
Last active March 28, 2024 10:36
Linking to a private repo in Cargo.toml

Under the dependencies section, put

<crate name>={git="ssh://git@github.com/<organization>/<reponame>.git"}

It is pretty similar to a github repo's ssh cloning link, however the : is replaced with a / and ssh:// is prepended to the URL.

git@github.com:my-organization/my-repo.git vs ssh://git@github.com/my-organization/my-repo.git

The SSH URL needs to be used because Cargo is currently unable to handle the authentication prompt that comes up when an HTTPS link is used.
Make sure that the matches the crate name in the target repo's Cargo.toml. The repo name will not override what is in the Cargo.toml if it is a different value.

@505aaron
505aaron / App.test.js
Last active July 21, 2020 08:15
createPortal Mock for react-test-renderer
jest.mock('react-dom');
import React from 'react';
import { createPortal } from 'react-dom';
import renderer from 'react-test-renderer';
import ShallowRenderer from 'react-test-renderer/shallow';
import ReactDOM from 'react-dom';
class Drop extends React.Component {
constructor(props) {
PostgreSQL Type PostgreSQL Size Description Range Diesel Type Rust Type
Nullable Types nullable Nullable``
@greyscaled
greyscaled / README.md
Last active September 19, 2022 08:59
Sequelize + Express + Migrations + Seed Starter