Skip to content

Instantly share code, notes, and snippets.

@mlegls
mlegls / contracts...Lootbox.sol
Created September 14, 2021 06:06
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
pragma solidity >=0.7.0 <0.9.0;
/**
* @title Lootbox
* @dev Matrix lootbox contract
*/
contract Lootbox {
enum TokenType{ NULL, NONFUNGIBLE, SEMIFUNGIBLE, FUNGIBLE }
@mlegls
mlegls / contracts...Lootbox.sol
Created September 15, 2021 21:04
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
pragma solidity >=0.7.0 <0.9.0;
/**
* @title Lootbox
* @dev Matrix lootbox contract
*/
contract Lootbox {
// NULL is for depleted items; fungible tokens not yet implemented
@mlegls
mlegls / contracts...Lootbox.sol
Created September 15, 2021 21:28
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
pragma solidity >=0.7.0 <0.9.0;
/**
* @title Lootbox
* @dev Matrix lootbox contract
*/
contract Lootbox {
// NULL is for depleted items; fungible tokens not yet implemented
@mlegls
mlegls / contracts...Lootbox.sol
Created September 15, 2021 21:47
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
pragma solidity >=0.7.0 <0.9.0;
/**
* @title Lootbox
* @dev Matrix lootbox contract
*/
contract Lootbox {
// NULL is for depleted items; fungible tokens not yet implemented
@mlegls
mlegls / contracts...Lootbox.sol
Created September 16, 2021 05:17
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
pragma solidity >=0.8.0 <0.9.0;
/**
* @title Lootbox
* @dev Matrix lootbox contract
*/
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";
import "@openzeppelin/contracts/token/ERC1155/utils/ERC1155Holder.sol";
// import "https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/token/ERC1155/ERC1155.sol";
@mlegls
mlegls / contracts...Lootbox.sol
Created September 16, 2021 19:06
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
pragma solidity >=0.8.0 <0.9.0;
/**
* @title Lootbox
* @dev Matrix lootbox contract
*/
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";
import "@openzeppelin/contracts/token/ERC1155/utils/ERC1155Holder.sol";
@mlegls
mlegls / contracts...Lootbox.sol
Created September 16, 2021 19:07
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
pragma solidity >=0.8.0 <0.9.0;
/**
* @title Lootbox
* @dev Matrix lootbox contract
*/
import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";
import "@openzeppelin/contracts/token/ERC1155/utils/ERC1155Holder.sol";
# Program shortcuts
shift + cmd - q : open -a "/Applications/qutebrowser.app"
shift + cmd - w : open -a "/Applications/kitty.app"
# Show system statistics
# fn + lalt - 1 : "${HOME}"/.config/yabai/scripts/show_cpu.sh
# fn + lalt - 2 : "${HOME}"/.config/yabai/scripts/show_mem.sh
# fn + lalt - 3 : "${HOME}"/.config/yabai/scripts/show_bat.sh
# fn + lalt - 4 : "${HOME}"/.config/yabai/scripts/show_disk.sh
# fn + lalt - 5 : "${HOME}"/.config/yabai/scripts/show_song.sh
#!/usr/bin/env bash
set -x
# ====== Variables =============================
declare -A gaps
declare -A color
gaps["top"]="4"
# If you come from bash you might have to change your $PATH.
export PATH=$HOME/bin:/usr/local/bin:$PATH
export PATH=/opt/homebrew/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH="$HOME/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME