Skip to content

Instantly share code, notes, and snippets.

View egyjs's full-sized avatar
:shipit:
The One Behind the Green Checkmark

AbdulRahman El-zahaby egyjs

:shipit:
The One Behind the Green Checkmark
View GitHub Profile
@egyjs
egyjs / Ollama-launch-claude-code-pass-arguments.md
Created May 13, 2026 23:53
Ollama launch Claude Code: pass `--resume`, `--dangerously-skip-permissions`, and other Claude CLI arguments

Ollama launch Claude Code: pass --resume, --dangerously-skip-permissions, and other Claude CLI arguments

TL;DR

Use -- to separate Ollama flags from Claude Code flags:

ollama launch claude --model minimax-m2.5:cloud -- --resume
@egyjs
egyjs / Anydesk Batch File.md
Created November 6, 2024 12:45
Fix AnyDesk Countdown Delay Issue - Anydesk Countdown Reset (100-second Issue) - إصلاح مشكلة العد التنازلي في AnyDesk

Fix AnyDesk Countdown Delay Issue - Anydesk Countdown Reset (100-second Issue) - إصلاح مشكلة العد التنازلي في AnyDesk

This batch script, anydesk-batch.bat, is designed to fix the AnyDesk 100-second countdown delay issue. It moves AnyDesk configuration files from their default locations to a backup folder named old. This solution targets files in both the AppData\Roaming\AnyDesk folder (user-specific) and ProgramData\AnyDesk folder (system-wide).

Purpose: Fixing the AnyDesk 100-Second Countdown

Occasionally, AnyDesk may mistakenly detect usage patterns that suggest you are using it for commercial purposes. As a result, it may trigger a 100-second delay popup, significantly slowing down your remote access experience. This script helps to reset AnyDesk's configuration files, moving them to an old folder, and potentially bypassing the delay and resetting AnyDesk's usage records that might be causing the popup.

Why You Need This Script

@egyjs
egyjs / Automating Postman to Swagger with Version Control in Laravel Vapor.md
Last active January 18, 2024 16:17
Automating Postman to Swagger with Version Control using GitHub Actions and Laravel

Title: Automating Postman to Swagger with Version Control in Laravel Vapor


Hey folks! 👋 I wanted to share a neat workflow I've implemented for our Laravel Vapor project that automates the generation and upload of Swagger documentation with each Git tag, all seamlessly integrated with Postman. 🚀

🤖 GitHub Actions Workflow (deploy.yml)

With every push to a dev/* tag, GitHub Actions springs into action:

@egyjs
egyjs / auto replace SRC,HREF with Laravel functions.md
Last active July 5, 2024 14:37
[laravel asset function] how to auto replace SRC,HREF with Laravel function using regex

This is the best I have so far using regex:

Find:

<((?!\s*((a)\s+))\w+)(.*?)((?:src|href)\s*=\s*")((?!\{\{\s*)[^"]+)"

Replace with:

&lt;$1$4$5{{ asset('$6') }}"
@fworks
fworks / install-zsh-windows-git-bash.md
Last active June 22, 2026 19:34
Zsh / Oh-my-zsh on Windows Git Bash
@egyjs
egyjs / .htaccess
Last active June 5, 2020 05:48
Laravel 5-6 – Remove Public from URL
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/public/
RewriteRule ^(.*)$ /public/$1 [L,QSA]
@egyjs
egyjs / php-html-css-js-minifier.php
Created July 10, 2019 11:53 — forked from Rodrigo54/php-html-css-js-minifier.php
PHP Function to Minify HTML, CSS and JavaScript
<?php
/**
* -----------------------------------------------------------------------------------------
* Based on `https://github.com/mecha-cms/mecha-cms/blob/master/system/kernel/converter.php`
* -----------------------------------------------------------------------------------------
*/
// HTML Minifier
function minify_html($input) {
@egyjs
egyjs / Lorem IpsumJS.md
Last active July 26, 2019 12:41
Lorem Ipsum - All the facts - Lipsum generator by javascript
@egyjs
egyjs / getImgFromString.php
Created June 11, 2018 03:42
PHP | get all <img> tag and extract the “src” attribute
<?php
function getImgFromString($html){
preg_match_all('/<img[^>]+>/i',$html, $result);
$img = array();
$i = 0;
foreach( $result[0] as $img_tag)
{
preg_match_all('/(src)="([^"]+)"/i',$img_tag, $img[$i]);
$i++;
@egyjs
egyjs / Direct Link of YouTube videos.md
Last active April 7, 2026 15:43
PHP API To get Direct Link of YouTube videos