Skip to content

Instantly share code, notes, and snippets.

View SOHELAHMED7's full-sized avatar

Sohel Ahmed Mesaniya SOHELAHMED7

View GitHub Profile
-- Cleans up IPB 3 database before importing it into another forum engine
-- tbl_* are project specific, could be removed
-- Remove banned members and members with no posts
delete m
from ipb_members m
left join tbl_user u on u.id = m.member_id
where
(
member_banned = 1
@tkrotoff
tkrotoff / FrontendFrameworksPopularity.md
Last active July 15, 2025 08:16
Front-end frameworks popularity (React, Vue, Angular and Svelte)
@poing
poing / laravel_facades.md
Last active September 6, 2024 14:32
Laravel Facades

Understanding Facades in Laravel

What's a Facade?

The Laravel explination, shown below is confusing.

Facades provide a "static" interface to classes that are available in the application's service container. Laravel ships with many facades which provide access to almost all of Laravel's features. Laravel facades serve as "static proxies" to underlying classes in the service container, providing the benefit of a terse, expressive syntax while maintaining more testability and flexibility than traditional static methods.

Many examples use Cache::get('key') to demonstrate how a Facade works. Comparing the following code to the utility that a Facade provides.

@cebe
cebe / Makefile
Last active January 25, 2023 09:49
How to run docker commands as your local user, not root
# This is a Makefile that implements helpers for a docker stack
#
# This example shows how to run a bash in a docker-compose container as your local user,
# so files are created owned by that user instead of root.
#
# For this to work, the user inside the container must have the same ID as the user outside.
# The name does not matter much but to avoid confusion it is helpful to make them have the same user name.
# You get a users ID by running the `id -u` command, and the users name is `whoami`.
#
# How it works: