Skip to content

Instantly share code, notes, and snippets.

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

Silvio Ney sneycampos

🏠
Working from home
  • Portugal
  • 09:57 (UTC +01:00)
View GitHub Profile
@Dowwie
Dowwie / socratic_fp_learning.md
Created June 7, 2025 09:23
Following is a prompt for effective learning with an LLM. It uses the Socratic method to help the student build up their understanding from first principles. Replace the topic in the prompt and then in your follow-up prompt , specify the subject.

You are a teacher of algorithms and data-structures who specializes in the use of the socratic method of teaching concepts. You build up a foundation of understanding with your student as they advance using first principles thinking. Explain the subject that the student provides to you using this approach. By default, do not explain using source code nor artifacts until the student asks for you to do so. Furthermore, do not use analysis tools. Instead, explain concepts in natural language. You are to assume the role of teacher where the teacher asks a leading question to the student. The student thinks and responds. Engage misunderstanding until the student has sufficiently demonstrated that they've corrected their thinking. Continue until the core material of a subject is completely covered. I would benefit most from an explanation style in which you frequently pause to confirm, via asking me test questions, that I've understood your explanations so far. Particularly helpful are test questions related to sim

@sneycampos
sneycampos / setup.sh
Created December 4, 2023 00:15
Setup new server
# Criar usuário "silvio"
sudo adduser silvio
# Adicionar "silvio" ao grupo "sudo"
sudo usermod -aG sudo silvio
# Criar pasta .ssh para o usuário "silvio" e arquivo authorized_keys
sudo mkdir /home/silvio/.ssh
sudo touch /home/silvio/.ssh/authorized_keys
@murdercode
murdercode / laravel-fastcgi-cache-config.md
Last active July 3, 2024 10:19
Optimizing Laravel (and Nova) with FastCGI Cache Configuration

Laravel + FastCGI Cache = ❤️

⚠️ Need a more specific guide? See https://medium.com/@murdercode/speed-up-your-laravel-application-up-to-1000x-with-fastcgi-cache-0135b11407e5

Using FastCGI cache allows you to speed up your website up to 1000x. In fact, the FastCGI cache (or Varnish) mechanism consists of putting a server-caching mechanism between a client and your web server. The whole page will be cached as an HTML output, and it will be delivered instead of using the PHP/MySQL/Redis stack, etc. for all users, but only for the first visit (and others after some specified time).

WARNING: This is not a take-away how-to. Please read it carefully and use it at your own risk.

This config is based on the ploi.io stack. We will not cover the FastCGI installation process, so please prepare FastCGI and adapt the next config if you need it.

@PhiloNL
PhiloNL / .env
Last active August 7, 2024 20:19
Simple, fast, and resilient open-source WebSockets server using Soketi with SSL in less than 5 minutes
PUSHER_HOST=socket.yourdomain.com
PUSHER_APP_ID=unlock
PUSHER_APP_KEY=123
PUSHER_APP_SECRET=456
PUSHER_PORT=443
PUSHER_SCHEME=https
@IgorDePaula
IgorDePaula / DockerFileEchoServer
Last active April 4, 2023 01:20
Laravel com redis e laravel-echo-server
# .docker/echo/Dockerfile
FROM node:erbium-alpine3.10
RUN npm install -g laravel-echo-server
RUN mkdir -p /var/www
WORKDIR /var/www
EXPOSE 6001
RUN ls /var/www
ENTRYPOINT laravel-echo-server start
@sneycampos
sneycampos / Ubuntu New Installation.sh
Last active November 29, 2022 10:19
Ubuntu Install
# Terminator
## https://github.com/gnome-terminator/terminator
# unbind default terminal command
# gsettings set org.gnome.settings-daemon.plugins.media-keys terminal '[]'
# Go to Settings -> Devices -> Keyboard and scroll to the end. Press + and you will create custom shortcut.
# Enter name: "terminator", command: /usr/bin/terminator -l "layout-custom"
sudo add-apt-repository ppa:mattrose/terminator