Skip to content

Instantly share code, notes, and snippets.

View fabiofdsantos's full-sized avatar

Fábio Santos fabiofdsantos

View GitHub Profile
@MelbourneDeveloper
MelbourneDeveloper / Stuff That Software Developers Do.md
Last active April 15, 2024 12:30
Stuff That Software Developers Do

Stuff That Software Developers Do

This is a list of stuff that the average software developer does from week to week

Coding

  • Code design
  • Refactoring
  • Algorithms
  • Profiling
  • Code reviews
  • Building frameworks
PHP 10 hrs 33 mins █████████████▍░░░░░░░ 64.0%
TypeScript 2 hrs 7 mins ██▋░░░░░░░░░░░░░░░░░░ 12.9%
Smarty 2 hrs 5 mins ██▋░░░░░░░░░░░░░░░░░░ 12.7%
Nginx 25 mins ▌░░░░░░░░░░░░░░░░░░░░ 2.5%
JavaScript 20 mins ▍░░░░░░░░░░░░░░░░░░░░ 2.0%
@amboutwe
amboutwe / yoast_seo_title_change-variable.php
Last active May 23, 2022 17:09
Change existing or add custom title or meta template variables
<?php
/********* DO NOT COPY THE PARTS ABOVE THIS LINE *********/
/* Remove Yoast SEO Change existing title or meta template variable
* Credit: Moshe Harush
* https://stackoverflow.com/questions/36281915/yoast-seo-how-to-create-custom-variables
* Last Tested: Unknown
*/
// define the wpseo_replacements callback
function filter_wpseo_replacements( $replacements ) {
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active November 18, 2024 16:45
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

pipeline {
agent any
stages {
stage('Prepare') {
steps {
sh 'composer install'
sh 'rm -rf build/api'
sh 'rm -rf build/coverage'
sh 'rm -rf build/logs'
@frankyonnetti
frankyonnetti / css-remove-hover-on-touch-screen-devices.css
Last active March 31, 2024 09:09
CSS - remove :hover on touch screen devices #css #ios
/*
* http://www.javascriptkit.com/dhtmltutors/sticky-hover-issue-solutions.shtml
* Method 3- Using CSS Media Queries Level 4 Interaction Media Features
*/
@media (hover:none),
(hover:on-demand) {
nav a:hover {
/* suppress hover effect on devices that don't support hover fully */
background: none;
@teepluss
teepluss / .bowerrc
Last active August 10, 2018 08:20
Config "AdminLTE" with Laravel Elixir
{
"directory": "./resources/assets/vendor"
}
@Kreshnik
Kreshnik / PreventReplayAttack.php
Last active November 6, 2024 14:25
Laravel 5 - PreventReplayAttack Middleware
<?php namespace App\Http\Middleware;
use Carbon\Carbon;
use Closure;
use Illuminate\Cache\Repository as Cache;
use Illuminate\Support\Facades\Response;
use Illuminate\Support\Facades\Session;
class PreventReplayAttack
{
@soheilhy
soheilhy / nginxproxy.md
Last active October 23, 2024 08:19
How to proxy web apps using nginx?

Virtual Hosts on nginx (CSC309)

When hosting our web applications, we often have one public IP address (i.e., an IP address visible to the outside world) using which we want to host multiple web apps. For example, one may wants to host three different web apps respectively for example1.com, example2.com, and example1.com/images on the same machine using a single IP address.

How can we do that? Well, the good news is Internet browsers

@lossendae
lossendae / timer.js
Created January 16, 2014 11:49
AngularJS timer with pause
var Controller = function($timeout){
var timer = 10000;
$scope.remaining = timer / 1000;
$scope.startTimer = function(){
$scope.timeout = $timeout(function() {
$scope.remaining--;
$scope.remaining > 0 ? $scope.startTimer() : $scope.finished('Finished!');
}, 1000);
};