Skip to content

Instantly share code, notes, and snippets.

View scodx's full-sized avatar
🏠
Working from home

Oscar Sánchez scodx

🏠
Working from home
View GitHub Profile
@dfletcher
dfletcher / mybartiksub.info.yml
Created October 7, 2019 14:38
Drupal 8 Quick Bartik subtheme
name: My Bartik subtheme
type: theme
core: 8.x
base theme: bartik
description: 'Bartik subtheme.'
alt text: 'Bartik subtheme.'
libraries:
- 'mybartiksub/theme'
@douglasrizzo
douglasrizzo / apple-kb-manjaro.md
Last active May 6, 2022 13:47
Connect Apple Keyboard to Manjaro Linux

Blueman does not help when connecting the Apple Keyboard to Manjaro. In the future, follow these steps to fully configure it. This needs package bluez-utils.:

  1. Get the device's MAC Address:
$ bluetoothctl
[bluetooth]$ power on
Changing power on succeeded
[bluetooth]$ devices
Device 00:11:22:33:44:55 Apple Wireless Keyboard
@bdlangton
bdlangton / Blocks.md
Last active October 12, 2023 08:40
Drupal 8 programmatic solutions

Render custom blocks

$bid = 'myblock';
$block = \Drupal\block_content\Entity\BlockContent::load($bid);
$render = \Drupal::entityTypeManager()->getViewBuilder('block_content')->view($block);

Render plugin blocks

$block_manager = \Drupal::service('plugin.manager.block');
@CyberPunkCodes
CyberPunkCodes / killadobe.sh
Last active November 21, 2022 16:41
Mac Bash script to kill Adobe Create Cloud and other processes that Adobe forces on us.
#!/bin/bash
echo "\n\n--- Killing Stupid Adobe Auto Load Crap ---\n\n"
launchctl unload -w /Library/LaunchAgents/com.adobe.AdobeCreativeCloud.plist
launchctl unload -w /Library/LaunchAgents/com.adobe.AAM.Updater-1.0.plist
echo "\n\n--- Done! ---\n\n"
@raphaellarrinaga
raphaellarrinaga / drupal_8_twig_cheatsheet.md
Last active July 20, 2023 21:21
[Drupal 8 Twig cheatsheet] #tags: drupal8, twig, cheatsheet

Drupal 8 Twig cheatsheet

Please note I created that sheet as a personal side note/draft and not everything is fully tested. There could be errors or better things to do. So if you spot something wrong or something that can be improved, feel free to comment below and I will do the changes.

Getting Drupal 8 field values in Twig

Image path: {{ file_url(content.field_name['#items'].entity.uri.value) }}

#!/usr/bin/env php
<?php
include_once 'app/global_vars.php';
require ROOT_DIR . 'vendor/autoload.php';
use Application\Command\InsertFixturesCommand;
use Symfony\Component\Console\Application;
@mbbx6spp
mbbx6spp / ALTERNATIVES.adoc
Last active July 6, 2024 19:43
Super quick list of alternatives to Jira and/or Confluence, Stash, Crucible, etc.
@dergachev
dergachev / README.md
Created October 10, 2012 16:49
Vagrant tutorial

Vagrant Setup

This tutorial guides you through creating your first Vagrant project.

We start with a generic Ubuntu VM, and use the Chef provisioning tool to:

  • install packages for vim, git
  • create user accounts, as specified in included JSON config files
  • install specified user dotfiles (.bashrc, .vimrc, etc) from a git repository

Afterwards, we'll see how easy it is to package our newly provisioned VM

@erikreagan
erikreagan / mac-apps.md
Created August 4, 2012 19:18
Mac developer must-haves

Mac web developer apps

This gist's comment stream is a collection of webdev apps for OS X. Feel free to add links to apps you like, just make sure you add some context to what it does — either from the creator's website or your own thoughts.

— Erik

@rbenaley
rbenaley / ssh_config
Created July 28, 2011 16:03
GitHub ssh access via HTTP Proxy
host github.com
user git
hostname ssh.github.com
port 443
proxycommand socat - PROXY:<hostname>:%h:%p,proxyport=<port>