Skip to content

Instantly share code, notes, and snippets.

View gskema's full-sized avatar

Gytis Šk. gskema

  • Kaunas, Lithuania
View GitHub Profile
@strawburrypokki
strawburrypokki / php-noinspection
Created February 22, 2018 14:22
PHPStorm PHP @noinspection
/* @noinspection PhpAbstractStaticMethodInspection */
/* @noinspection PhpHierarchyChecksInspection */
/* @noinspection PhpUnreachableStatementInspection */
/* @noinspection PhpUnusedLocalVariableInspection */
/* @noinspection PhpWrongCatchClausesOrderInspection */
/* @noinspection PhpDeprecationInspection */
/* @noinspection PhpDocMissingReturnTagInspection */
/* @noinspection PhpDocMissingThrowsInspection */
/* @noinspection PhpDocSignatureInspection */
/* @noinspection PhpMissingDocCommentInspection */
@titpetric
titpetric / graphql-mini.php
Created April 11, 2017 08:47
Transform GraphQL fields into JSON to use them for filtering native PHP arrays
<?php
/** A poor mans GraphQL fields parser
*
* Try to convert graphQL fields to JSON and then just use json_decode to produce an array.
*/
class Fields
{
/** Parse GraphQL fields into an array */
public static function parse($query)
// Talking console
//
// Support: http://caniuse.com/#search=SpeechSynthesisUtterance
//
// Copy paste the code into dev console or
// use http://mrcoles.com/bookmarklet/ to create a bookmarklet.
/* ✂️ ......................................................................................... */
if(console.log.name !== 'talkLog') {
console.l = console.log;
@jimbocoder
jimbocoder / 14.04-bloat-packages
Created August 10, 2014 20:30
Ubuntu 14.04 Desktop bloat removal package list
# Purge the following packages
account-plugin-aim
account-plugin-facebook
account-plugin-flickr
account-plugin-jabber
account-plugin-salut
account-plugin-twitter
account-plugin-windows-live
account-plugin-yahoo
@heristop
heristop / autoTranslate.php
Last active July 1, 2016 06:40
Use Google Translate API through YQL
<?php
trait autoTranslate
{
protected
$lang1,
$lang2
;
protected function translate($text)
@Im0rtality
Im0rtality / README.md
Last active March 17, 2023 14:36
PHP CLI Debugging in Vagrant using Xdebug and PHPStorm

In host:

  1. Go to PHPStorm Settings > Project settings > PHP > Servers
  2. Add server with following parameters:
    • Name: vagrant (same as serverName= in debug script)
    • Host, port: set vagrant box IP and port
    • Debugger: Xdebug
    • [v] Use path mappings
    • Map your project root in host to relative dir in guest
  • Hit OK
@Integralist
Integralist / GitHub curl.sh
Last active September 7, 2023 03:53 — forked from madrobby/gist:9476733
Download a single file from a private GitHub repo. You'll need an access token as described in this GitHub Help article: https://help.github.com/articles/creating-an-access-token-for-command-line-use
curl --header 'Authorization: token INSERTACCESSTOKENHERE' \
--header 'Accept: application/vnd.github.v3.raw' \
--remote-name \
--location https://api.github.com/repos/owner/repo/contents/path
# Example...
TOKEN="INSERTACCESSTOKENHERE"
OWNER="BBC-News"
REPO="responsive-news"
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active May 5, 2024 18:31
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@rxaviers
rxaviers / gist:7360908
Last active May 6, 2024 17:53
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue: