This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Meta (Instagram, Facebook) | |
// Узлы | |
157.240.253.174, 157.240.253.172, 157.240.253.167, 157.240.253.63, 157.240.253.32 | |
157.240.252.174, 157.240.252.172, 157.240.252.167, 157.240.252.63, 157.240.252.38 | |
57.144.112.34, 57.144.110.1, 157.240.205.174 | |
// Подсети | |
213.102.128.0/24 | |
204.15.20.0/22 | |
199.201.0.0/16 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Create a group | |
CREATE ROLE readaccess; | |
-- Grant access to existing tables | |
GRANT USAGE ON SCHEMA public TO readaccess; | |
GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess; | |
-- Grant access to future tables | |
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// by using KingPin | |
sSep = app.Flag("separator", "Separator to use in csv file (in read and write) [default is ','].").Short('s').Default(",").String() | |
// Need to cast *sSep in rune for option Comma in "encoding/csv" | |
w.Comma = bytes.Runes([]byte(*sSep))[0] // fr => converti la chaine en tableau de bytes, pour apres la convertir en rune | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// A very simple example about how to use concurrent-safe SETs (using string as keys) in GO | |
package main | |
import ( | |
"fmt" | |
"sync" | |
) | |
type Set struct { | |
m map[string]bool |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git stash show -p stash@{0} > Stash0.patch |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Recursive file convertion windows-1251 --> utf-8 | |
# Place this file in the root of your site, add execute permission and run | |
# Converts *.php, *.html, *.css, *.js files. | |
# To add file type by extension, e.g. *.cgi, add '-o -name "*.cgi"' to the find command | |
find ./ -name "*.php" -o -name "*.html" -o -name "*.css" -o -name "*.js" -type f | | |
while read file | |
do |