Skip to content

Instantly share code, notes, and snippets.

View kuwaitbinary's full-sized avatar
💭
Surviving sometimes I am free sometimes I am busy

Abdullah Al Mashmoum kuwaitbinary

💭
Surviving sometimes I am free sometimes I am busy
  • Kuwait
View GitHub Profile
@mhulse
mhulse / Super simple background image slideshow.css
Last active January 18, 2020 12:46
Super simple jQuery background-image random slideshow (using CSS3 for the transition and gets the image paths via HTML5 `data` attribute).
[data-slides] {
background-image: url(../../uploads/banner1.jpg); /* Default image. */
background-repeat: no-repeat;
background-position: center top;
background-size: cover;
transition: background-image 1s linear;
}
/* Use additional CSS to control the `height` of `[data-slides]`, like so: */
@Zenexer
Zenexer / Mac Keyboard Symbols.md
Last active December 7, 2024 17:57
List of Mac/Apple keyboard symbols
@gokulkrishh
gokulkrishh / media-query.css
Last active July 24, 2025 23:21
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
/* CSS */
@aint
aint / I2P OS X.md
Last active September 23, 2024 01:11
Set Up I2P on Mac OS X
  • Install I2P
    • Download I2P
    • java -jar i2pinstall_*.jar
  • Install Java Service Wrapper
    • Download Community Version
    • tar xzf wrapper-*.tar.gz
    • cp wrapper*/bin/wrapper /Applications/i2p/i2psvc
    • cp wrapper*/lib/wrapper.jar /Applications/i2p/lib
    • cp wrapper*/lib/libwrapper.so /Applications/i2p/lib
  • Try to start I2P using /Applications/i2p/i2prouter start or Start I2P Router app
@n1zyy
n1zyy / trackers.md
Last active May 28, 2025 23:07
Live Torrent Trackers

I was hacking on a little side-project, and found that most lists of torrent trackers are full of defunct trackers, or lots of dupes. I spent a while going through all the lists on the first few pages of Google, compiling them into a giant list, de-duping it, and then writing some quick code to test all of them.

Also, an aside: "/announce" on the end of a UDP URL doesn't make any sense. It's completely ignored at the protocol level, so I normalized entries by removing it.

I don't endorse any of these trackers, nor suggest you use them for committing copyright infringement.

Straight list

These trackers all respond to at least some scrape queries:

@ankurk91
ankurk91 / git_remember_password.md
Last active March 24, 2025 03:03
Git credential cache, why type password again and again

Tired of entering passwords again and again ?

Run this command to remember your password:

git config --global credential.helper 'cache --timeout 28800'

Above command will tell git to cache your password for 8 hours.

@jahe
jahe / spring-boot-cheatsheet.java
Last active October 8, 2024 00:10
Spring Boot Cheatsheet
// Enable component-scanning and auto-configuration with @SpringBootApplication Annotation
// It combines @Configuration + @ComponentScan + @EnableAutoConfiguration
@SpringBootApplication
public class FooApplication {
public static void main(String[] args) {
// Bootstrap the application
SpringApplication.run(FooApplication.class, args);
}
}

Common Apache Commands and Features

Commands

Checks Syntax of Configuration Files

apachectl -t

Lists Loaded modules

@rudelm
rudelm / autofs.md
Last active July 7, 2025 20:18
Use autofs on Mac OS X to mount network shares automatically during access

Autofs on Mac OS X

With autofs you can easily mount network volumes upon first access to the folder where you want to mount the volume. Autofs is available for many OS and is preinstalled on Mac OS X so I show you how I mounted my iTunes library folder using this method.

Prepare autofs to use a separate configuration file

autofs needs to be configured so that it knows where to gets its configuration. Edit the file /etc/auto_master and add the last line:

#
# Automounter master map
#

+auto_master # Use directory service

@joerx
joerx / php-fpm-nginx-errorlog.md
Last active August 6, 2023 16:49
redirect php-fpm output to nginx's error log
  • php process is wrapped like this: PHP file -> php-fpm -> nginx
  • basically means disable all facilities that catch output from the script on it's way to nginx
  • standard error output will the end in Nginx's logging facility

On CentOS

  • make sure your script does not set error_log
  • edit /etc/php-fpm.conf, disable line error_log = /var/log/php-fpm/error.log
  • edit /etc/php-fpm.d/www.conf, disable line starting with php_admin_value[error_log] = ...
  • restart fpm: systemctl restart php-fpm