Skip to content

Instantly share code, notes, and snippets.

View afkvido's full-sized avatar
:electron:
rush

gemsvidø afkvido

:electron:
rush
View GitHub Profile
@jadeatucker
jadeatucker / HOWTODMG.md
Last active May 29, 2024 21:16
How to create a "DMG Installer" for Mac OS X

Creating a "DMG installer" for OS X

A DMG Installer is convenient way to provide end-users a simple way to install an application bundle. They are basically a folder with a shortcut to the Applications directory but they can be customized with icons, backgrounds, and layout properties. A DMG file (.dmg) is a Mac OS X Disk Image file and it is used to package files or folders providing compression, encryption, and read-only to the package.

##Creating the DMG file #Disk Utility

@GiriB
GiriB / OpenUrl.java
Last active April 15, 2023 05:16
Open a URL in the default browser from Java
import java.awt.Desktop;
import java.io.IOException;
import java.net.URI;
import java.net.URISyntaxException;
public static void main(String args[]){
Desktop desktop = java.awt.Desktop.getDesktop();
try {
//specify the protocol along with the URL
URI oURL = new URI(
According to all known laws of aviation, there is no way a bee should be able to fly.
Its wings are too small to get its fat little body off the ground.
The bee, of course, flies anyway because bees don't care what humans think is impossible.
Yellow, black. Yellow, black. Yellow, black. Yellow, black.
Ooh, black and yellow!
Let's shake it up a little.
Barry! Breakfast is ready!
Coming!
Hang on a second.
Hello?
According to all known laws of aviation, there is no way a bee should be able to fly.
Its wings are too small to get its fat little body off the ground.
The bee, of course, flies anyway because bees don't care what humans think is impossible.
Yellow, black. Yellow, black. Yellow, black. Yellow, black.
Ooh, black and yellow!
Let's shake it up a little.
Barry! Breakfast is ready!
Coming!
Hang on a second.
Hello?
@PatheticMustan
PatheticMustan / Discord Tag Rerolling.md
Last active May 26, 2023 04:04
My notes on Discord tag re-rolling.

Discord Tag Rolling

When many users want to use a username that's taken, most software platforms solve this by just forcing them to choose another username. Discord has an interesting solution to this problem: giving people random 4 digit tags as well as their usernames! This allows for many users to have the same username while allowing each person to have a unique username that's easy to remember.

Some notes:

  • Discord's tag system makes it possible to have 9_999 people with the same username, but they limit people from using popular names at a certain point.
  • Discord's Nitro subscription system allows users to change their tag to any untaken tag. Their tags are randomized once their Nitro subscription ends.
  • There is a rate limit of 2 name/tag changes per hour.
@R1DD1387
R1DD1387 / Prodigy Mod Menu V.1
Created February 28, 2020 12:37
Modmenu for the game Prodigy
function closeit(){
prodigydiv.remove()
}
setTimeout("closeit", 3000);
function getallCurrencies() {
PIXI.game.prodigy.player.backpack.data.currency=[]
x = PIXI.game.state.states.Boot._gameData.currency
for (i in x) {
PIXI.game.prodigy.player.backpack.data.currency[i] = {"ID": x[i].ID, "N": 9999999999}
}
@afkvido
afkvido / soon.md
Created February 17, 2022 22:56
Coming soon gist

Coming Soon™

<!DOCTYPE html>
<html>
<head>
<title>
<!--This is what will be displayed at the top of your page-->
</title>
</head>
<body>
<h1>This is a Heading</h1>
According to all known laws of aviation, there is no way a bee should be able to fly.
Its wings are too small to get its fat little body off the ground.
The bee, of course, flies anyway because bees don't care what humans think is impossible.
Yellow, black. Yellow, black. Yellow, black. Yellow, black.
Ooh, black and yellow!
Let's shake it up a little.
Barry! Breakfast is ready!
Coming!
Hang on a second.
Hello?
@afkvido
afkvido / Fetch.kt
Last active February 28, 2023 21:16
Read data from URL in Kotlin.
import java.net.URI
import java.net.URL
import java.util.*
/** Get text from an online resource */
fun fetch (url : URL) : String {
println("Fetching resource from $url")
return Scanner(url.openStream(), "UTF-8").useDelimiter("\\A").next()
}