Skip to content

Instantly share code, notes, and snippets.

View elsayed85's full-sized avatar
💻
chilling 💤

Elsayed Kamal elsayed85

💻
chilling 💤
View GitHub Profile
#!/usr/bin/env bash
#
TEMPERATURE=${TEMPERATURE:-0}
MAX_TOKENS=${MAX_TOKENS:-1000}
MODEL=${MODEL:-"text-davinci-003"}
message="$*"
token=""
clear_command="wipe"
@elsayed85
elsayed85 / install-docker.sh
Created October 29, 2022 21:46 — forked from madkoding/install-docker-deepin.sh
Install Docker-CE script for Deepin Linux
#!/bin/sh
# Shell script to add docker-ce to Deepin Linux repositories
# Remove old docker
sudo apt-get remove -y docker docker-engine docker.io containerd runc
# Install dependencies
sudo apt-get install -y apt-transport-https ca-certificates curl gnupg2 software-properties-common

Using Git to Manage a Live Web Site

Overview

As a freelancer, I build a lot of web sites. That's a lot of code changes to track. Thankfully, a Git-enabled workflow with proper branching makes short work of project tracking. I can easily see development features in branches as well as a snapshot of the sites' production code. A nice addition to that workflow is that ability to use Git to push updates to any of the various sites I work on while committing changes.

Contents

@elsayed85
elsayed85 / assets.md
Last active March 26, 2022 20:00
laravel resources
@elsayed85
elsayed85 / c
Created September 13, 2021 18:12
<?php
// Disable login (don't ask for credentials, be careful)
// Example: $NO_LOGIN = true;
$NO_LOGIN = false;
// Single-user credentials
// Example: $USER = 'user'; $PASSWORD = 'password';
$USER = 'fr3on';
$PASSWORD = '2c528ade717cb4c7f2cf4f44555db1e3bb67322792c73d85e4e3723101b1cbf6';
<?php
/**
* Load correct autoloader depending on install location.
*/
if (file_exists(__DIR__ . '/../vendor/autoload.php')) {
require_once __DIR__ . '/../vendor/autoload.php';
} else {
require_once __DIR__ . '/../../../autoload.php';
}
alias winpwd='cygpath -aw .'
alias clearlog='rm $(winpwd)/storage/logs/laravel.log'
alias clearlogs='find $(winpwd)/storage/logs -name '*.log' -delete'
<?php
namespace App\Console\Commands\GenLib;
use goutte;
use Illuminate\Console\Command;
use Symfony\Component\Console\Helper\Table;
class Search extends Command
{
<?php
return [
"vapulus" => [
"baseurl" => "https://api.vapulus.com:1338/",
"failUrl" => "",
"successUrl" => "",
'app_id' => env('VAPULUS_AppID'),
'password' => env('VAPULUS_password'),
'hash' => env('VAPULUS_HASH')
]