Skip to content

Instantly share code, notes, and snippets.

View nullbuddy1243's full-sized avatar

nullbuddy1243

  • US North East
View GitHub Profile
const Web3 = require('web3')
const packsAddr='0xEEd41d06AE195CA8f5CaCACE4cd691EE75F0683f'
const main = async () => {
const rpcURL = 'https://mainnet.infura.io/v3/{yr infura code}'
let web3 = new Web3(rpcURL)
const bytecode = await web3.eth.getCode(packsAddr)
console.log({
@nullbuddy1243
nullbuddy1243 / marketplace.sol
Created April 22, 2022 17:54 — forked from dabit3/marketplace.sol
NFT Marketplace Smart Contract (V2)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;
import "@openzeppelin/contracts/utils/Counters.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol";
import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "hardhat/console.sol";
contract NFTMarketplace is ERC721URIStorage {
@nullbuddy1243
nullbuddy1243 / .deps...npm...@openzeppelin...contracts...access...Ownable.sol
Created February 23, 2022 04:02
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=
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/Ownable.sol)
pragma solidity ^0.8.0;
import "../utils/Context.sol";
/**
* @dev Contract module which provides a basic access control mechanism, where
* there is an account (an owner) that can be granted exclusive access to
SELECT view_serviceinstance_v1.*,
service.name AS service_name,
service.vendor_fk AS service_vendor,
device.name AS device_name
FROM view_serviceinstance_v1
LEFT OUTER JOIN view_service_v1 AS service ON view_serviceinstance_v1.service_fk=service.service_pk
LEFT OUTER JOIN view_device_v1 AS device ON view_serviceinstance_v1.device_fk=device.device_pk
@nullbuddy1243
nullbuddy1243 / FrequencyModulationSynth.scd
Created April 9, 2016 02:53
Simple Frequency Modulation Synth, written in Supercollider
(
SynthDef(\fm, {
|freq=200, atk=0.01, decay=0.3, sustain=0.4, rel=0.1
carratio=1,modratio=1, modindex=1,
amp=0.2, gate=1, outBus=0|
var env = EnvGen.kr(Env.adsr(atk, decay, sustain, rel), gate, doneAction:2);
var mod = SinOsc.ar(freq * modratio);
var car = SinOsc.ar(freq * carratio + (1 + (mod *modindex)), 0) * amp * env;
Out.ar(0, car ! 2);
@nullbuddy1243
nullbuddy1243 / hacker-radiio
Created April 1, 2016 05:15 — forked from jars/hacker-radiio
Music For Hackers
Music For Hackers
==
To a hacker, there's something distracting about booting up a GUI to listen to your tunes. You live your life in the terminal, you treat the mouse like a high voltage tap.
So give these commands a run in the terminal, and toss on your headphones.
sudo apt-get install mplayer
echo "alias defcon-start='nohup mplayer http://sfstream1.somafm.com:6200 > /dev/null 1>&2 &'" >> ~/.bashrc
echo "alias defcon-stop='killall -9 mplayer'" >> ~/.bashrc