Skip to content

Instantly share code, notes, and snippets.

View pronskiy's full-sized avatar
🐘
🇺🇦

Roman Pronskiy pronskiy

🐘
🇺🇦
View GitHub Profile
@voku
voku / gist:4ad5a27836ae7c5100b746848e30d278
Last active October 11, 2023 21:48
Me as chat bot. 😁
Respond with tree of thought reasoning in the persona of a senior php developer and architect "Lars Moelleken" (github.com/voku) who does code reviews and curses a lot. He writes modern / strict php code with types and if needed with phpdoc annotations from phpstan (for example : generics, array shapes, int-ranges, non-empty-strings or class-strings). He already applied php-cs-fixer, php-sniffer and phpstan max level and fixed all reported problems in the generated code. He prefers real objects instead of arrays, immutable classes, final methods, private or readonly / typed properties and always applies best practice OOP design patterns in the code while beng very concise and calculative like this:
📉Kanban:"A kanban table of the project state with todo, doing, done columns."
🧐Problem: "A {system 2 thinking} description of the problem in first principles and super short {system 1 thinking} potential solution."
🌳Root Cause Analysis (RCA):"Use formal troubleshooting techniques like the ones that electricians, m
<?
//
// AUTO KEYWORD-BASED FOLLOWER CURATION BOT (by @levelsio)
//
// File: twitterFollowerCuratorBot.php
//
// Created: May 2021
// License: MIT
//

Twitter abuses all media file uploads, each type in its own way. If we want to upload a good looking animation loop from some low-color, high-detail generative art, we have to game their system's mechanisms.

  • don't upload a video file, they will re-encode it into absolute 💩

  • create a GIF, which they will auto-convert into a video file 😱

  • The frames of the GIF will be resized to an even-sized width using an extremely naive algorithm. Your GIF should be an even size (1000, 2000,

@Ocramius
Ocramius / psalm-compendium.php
Last active November 9, 2023 07:27
A small compendium of what is possible with `vimeo/psalm` 3.9.x to add some decent type system features to PHP
<?php
// -- types are a compile-time propagated concept
// https://psalm.dev/r/338f74a96c
class TheType
{
/** @var string */
public $foo = 'bar';
}
@IanColdwater
IanColdwater / twittermute.txt
Last active April 22, 2024 17:26
Here are some terms to mute on Twitter to clean your timeline up a bit.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@Seldaek
Seldaek / ext-requires.txt
Last active February 15, 2020 18:52
PHP Extension Requirements on Packagist.org
Taken from packagist.org
Packages with a master branch update since June 1st 2018: 98977
Of those, package having requires on PHP extensions: 11676 (11.79%)
As only ~12% of packages declare their extension requirements,
and even then it might not be a complete list, take all this with
a big grain of salt, it is informative but definitely not a
complete picture of the most used extensions.
@RedRoxProjects
RedRoxProjects / Amy-Dickens-CV.md
Last active February 25, 2020 13:11
Need a Developer Advocate or Community Manager? -> Hire me.

ABOUT ME

Hi folks 👋

I'm Amy, a Developer Advocate & all round community kind of person.:sparkles:

I've been doing a lot of developer community flavoured things since starting my PhD in Computer Science in 2015 🎓. Including organising the Inspire WiT conference (a conference to help women and other underrepresented folks get into technology based in the midlands UK) in 2016 & 2017 👩‍💻 👩‍🔬.

My CV

CV

@icanhazstring
icanhazstring / .travis.yml
Created February 14, 2019 15:00
Enable Travis PHP Build on Windows
# default os is linux
matrix:
include:
- language: php
php: 7.2
before_script:
- composer install
after_script:
- sh .travis.coverage.sh
@Leneshka-jb
Leneshka-jb / XBladeLanguageInjector.java
Created January 15, 2019 15:44
XBlade-style php injection
package com.jetbrains.php.blade.injection;
import com.intellij.openapi.util.TextRange;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.psi.*;
import com.intellij.psi.xml.XmlAttribute;
import com.intellij.psi.xml.XmlAttributeValue;
import com.jetbrains.php.blade.BladeFileType;
import com.jetbrains.php.lang.PhpLanguage;
import org.jetbrains.annotations.NotNull;
@jeremeamia
jeremeamia / php-library-building.md
Created November 28, 2018 09:24
List of resources to help with building libraries