Skip to content

Instantly share code, notes, and snippets.

View ramazansancar's full-sized avatar
๐Ÿ“š
Study

Ramazan Sancar ramazansancar

๐Ÿ“š
Study
View GitHub Profile
@ahmedhalima
ahmedhalima / script.sh
Created April 14, 2018 22:44
install ipvtl trial and hack its trial
#!/bin/bash
echo "Downloading ipvtl Software \n"
cd /home
wget http://www.ipvideotrans.com/download/ipvtl_trial-x64.tar.xz
@sun4lower
sun4lower / NginxReloadBug
Created February 28, 2018 08:57
nginx: [error] invalid PID number "" in "/var/run/nginx.pid"
pkill -9 nginx
nginx -c /etc/nginx/nginx.conf
nginx -s reload
@zentala
zentala / simpleDownloadServer.js
Last active January 1, 2023 19:21
Node & Express file downloading in 4 lines!
const app = require('express')()
const path = require('path')
const filePath = path.join(__dirname, 'raport.csv')
app.get('/', (req, res) => res.download(filePath))
app.listen(3000, () => console.log(`Server listening on port 3000!`))
// 1) Locate `node simpleDownloadServer.js` and `raport.csv` in the same directory
// 2) Execute in console `npm init && npm install express`, and then `node simpleDownloadServer.js`
// 3) Open in browser `http://localhost:3000/` in order to download `raport.csv`
@SpaceOyster
SpaceOyster / mastodon-icon.html
Last active April 14, 2024 20:04
Mastodon.social svg icon
<svg viewBox="0 0 16 16" width="16" height="16"><path fill="#828282" d="M 15.659 9.592 C 15.424 10.72 13.553 11.956 11.404 12.195 C 10.283 12.32 9.18 12.434 8.003 12.384 C 6.079 12.302 4.56 11.956 4.56 11.956 C 4.56 12.13 4.572 12.297 4.595 12.452 C 4.845 14.224 6.478 14.33 8.025 14.379 C 9.586 14.429 10.976 14.02 10.976 14.02 L 11.04 15.337 C 11.04 15.337 9.948 15.884 8.003 15.984 C 6.93 16.039 5.598 15.959 4.047 15.576 C 0.683 14.746 0.104 11.4 0.015 8.006 C -0.012 6.998 0.005 6.048 0.005 5.253 C 0.005 1.782 2.443 0.765 2.443 0.765 C 3.672 0.238 5.782 0.017 7.975 0 L 8.029 0 C 10.221 0.017 12.332 0.238 13.561 0.765 C 13.561 0.765 15.999 1.782 15.999 5.253 C 15.999 5.253 16.03 7.814 15.659 9.592 Z M 13.124 5.522 L 13.124 9.725 L 11.339 9.725 L 11.339 5.646 C 11.339 4.786 10.951 4.35 10.175 4.35 C 9.317 4.35 8.887 4.867 8.887 5.891 L 8.887 8.124 L 7.113 8.124 L 7.113 5.891 C 7.113 4.867 6.683 4.35 5.825 4.35 C 5.049 4.35 4.661 4.786 4.661 5.646 L 4.661 9.725 L 2.876 9.725 L 2.876 5.522 C 2.876 4.663 3.111 3.9
@thomasbnt
thomasbnt / code_colors_discordjs.md
Last active July 18, 2026 00:50
Code colors for embed discord.js

Here is an updated list of the colors that are currently implemented with a name. To using colors on discord.js, this is a typedef Colors, Colors.Aqua to get the Aqua color.

Name Int value Hex Code
Default 0 #000000
Aqua 1752220 #1ABC9C
DarkAqua 1146986 #11806A
Green 5763719 #57F287
DarkGreen 2067276 #1F8B4C
@GokhanPolat
GokhanPolat / youtube-dl.sh
Last active October 21, 2022 07:36
Download youtube video as mp3
# For file convention youtube-dl uses "ffmpeg"
# Don't forget install the necessary packages.
# if single video link
youtube-dl -i --extract-audio --audio-format mp3 [youtube link]
# if playlist link with desired naming convention
youtube-dl -i --extract-audio --audio-format mp3 -o "%(playlist_index)s-%(title)s.%(ext)s" [youtube link]
@cprakashagr
cprakashagr / LICENCE SUBLIME TEXT
Last active May 3, 2026 17:08
Sublime Text 3 Serial key build is 3143
## Sublime Text 3 Serial key build is 3103
โ€”โ€“ BEGIN LICENSE โ€”โ€“
Michael Barnes
Single User License
EA7E-821385
8A353C41 872A0D5C DF9B2950 AFF6F667
C458EA6D 8EA3C286 98D1D650 131A97AB
AA919AEC EF20E143 B361B1E7 4C8B7F04
B085E65E 2F5F5360 8489D422 FB8FC1AA
@zentala
zentala / formatBytes.js
Created September 27, 2017 11:57
Convert size in bytes to human readable format (JavaScript)
function formatBytes(bytes,decimals) {
if(bytes == 0) return '0 Bytes';
var k = 1024,
dm = decimals || 2,
sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],
i = Math.floor(Math.log(bytes) / Math.log(k));
return parseFloat((bytes / Math.pow(k, i)).toFixed(dm)) + ' ' + sizes[i];
}
// Usage:
@andreasonny83
andreasonny83 / .gitignore
Last active June 24, 2026 15:13
Gitignore template for JavaScript projects
# See http://help.github.com/ignore-files/ for more about ignoring files.
# compiled output
/dist
/tmp
/out-tsc
# Runtime data
pids
*.pid
@enginkartal
enginkartal / js-turkish-to-english.js
Last active April 22, 2024 13:11
Javascript Turkish character to english characters change
String.prototype.turkishtoEnglish = function () {
return this.replace('ฤž','g')
.replace('รœ','u')
.replace('ลž','s')
.replace('I','i')
.replace('ฤฐ','i')
.replace('ร–','o')
.replace('ร‡','c')
.replace('ฤŸ','g')
.replace('รผ','u')