Skip to content

Instantly share code, notes, and snippets.

View HenestrosaDev's full-sized avatar

HenestrosaDev

View GitHub Profile
@HenestrosaDev
HenestrosaDev / validation.php
Created May 20, 2024 11:37
Traducción en español del archivo `lang/es/validation.php` para Laravel 10
<?php
return [
/*
|--------------------------------------------------------------------------
| Validation Language Lines
|--------------------------------------------------------------------------
|
| The following language lines contain the default error messages used by
@HenestrosaDev
HenestrosaDev / visual-studio-code-shortcuts.md
Last active June 11, 2022 12:25
Visual Studio Code Shortcuts.md

VISUAL STUDIO CODE SHORTCUTS

Note

There are some shortcuts that are not exclusive to Visual Studio Code. I decided to add them because they are a positive addition to the list. They are marked with an asterisk

  • *: Non-exclusive VS Code shortcut.
  • #: Needs to be configured by the user using the Keyboard Shortcuts option.

@HenestrosaDev
HenestrosaDev / useful-finder-commands.md
Last active June 11, 2022 00:10
Useful Finder commands

USEFUL FINDER COMMANDS

  • Enter path: Command + Shift + G
  • Toggle visibility of hidden files and directories: Command + Shift + .
@HenestrosaDev
HenestrosaDev / desplegar-proyecto-laravel-en-heroku.md
Last active June 11, 2022 00:00
Desplegar proyecto Laravel en Heroku

DESPLEGAR PROYECTO LARAVEL EN HEROKU

  1. Creamos la aplicación en Heroku.
  2. En la pestaña Resources, vamos a la sección Add-ons y buscamos Heroku Postgres.
  3. Seleccionamos el plan gratuito del add-on y lo vinculamos a nuestro proyecto.
  4. Hacemos click sobre Heroku Postgres y vamos a la pestaña Settings.
  5. En la lista que aparece, le damos al botón View Credentials…
  6. Copiamos y pegamos los datos en el archivo .env de nuestro proyecto. Importante poner DB_CONNECTION=pgsql.
  7. En la raíz del directorio, creamos el archivo Procfile y añadimos web: vendor/bin/heroku-php-apache2 public/.
  8. Abrimos la CLI en la raíz del proyecto y ejecutamos los siguientes comandos:
@HenestrosaDev
HenestrosaDev / linux-commands.md
Last active April 17, 2022 11:11
Linux commands

LINUX COMMANDS

Some things that you need to know beforehand

  • The explanation of the programs and commands is based on my understanding of them. However, I have contrasted them using the program man and the flag --help as a reference in order to give the simplest yet most accurate explanation to each one. Every external reference has been indicated in its respective part.
  • You might be missing some programs/flags. I am listing the ones that I have used so far, so I might be overlooking some useful utilities. Feel free to improve the list with the addition of more, with their respective explanation.
  • If you have any trouble finding out what a program does, simply use man [PROGRAM], info [PROGRAM] or whatis [PROGRAM] to retrieve more information about it.
  • Some commands are written like this one: rm [-r|--recursive]. That means that the commands rm -r and rm --recursive are both possible inputs. If the description of a command like this does not specify the diffe
@HenestrosaDev
HenestrosaDev / artisan-cheatsheet.md
Last active March 8, 2025 21:49
Laravel PHP Artisan cheatsheet en español

PHP ARTISAN CHEATSHEET EN ESPAÑOL

IMPORTANTE

Aquellos trozos de código que estén comprendidos entre [] (por ejemplo, [NOMBRE]) deben de ser reemplazados por el nombre de una migración, tabla… Dependiendo de la función del comando que se vaya a utilizar.

Un ejemplo de ello sería el comando php artisan make:model [NOMBRE] -m. Si se quiere crear un modelo que se llame User, se tendría que ejecutar php artisan make:model User -m.

Otro aspecto a tener en cuenta es que las flags (--seed, --inline…) pueden ser combinables, aunque no siempre es así. Por ejemplo, --invokable y --resource no se pueden ejecutar en el mismo comando puesto que la acción de cada una entraría en conflicto.