xxxxxxxxxx
php artisan make:migration add_paid_to_users_table --table=users
xxxxxxxxxx
php artisan make:migration update_user_guide_in_product_translations_table
xxxxxxxxxx
#create model
php artisan make:model Model_Name
#create model with migration
php artisan make:model Model_Name -m
#create model with migration and controller
php artisan make:model Model_Name -mcr
xxxxxxxxxx
composer require doctrine/dbal
php artisan make:migration add_end_at_filed_to_appointment_table
xxxxxxxxxx
To Generate Laravel Migrations from an existing database.
Use the following package.
https://github.com/Xethron/migrations-generator
xxxxxxxxxx
require('dotenv').config()
console.log(process.env) // remove this after you've confirmed it is working
xxxxxxxxxx
must install dotenv package from terminal using
yarn add --dev dotenv
// this is under config.js
require("dotenv").config();
// RPC_url & Private key masked by dotenv
const GOERLI_RPC_URL = process.env.GOERLI_RPC_URL;
const PRIVATE_KEY = process.env.PRIVATE_KEY;
// This are under .env
GOERLI_RPC_URL = https://eth-goerli.g.alchemy.com/v2/QQCTg89Ei5ZfBUQ0Y5g0j_aN2PwmwX67
PRIVATE_KEY = f8494e7b7d5a8bd284150015ac99074c12ff3d7f06d574c837ea6a2a78918a17
ETHERSCAN_API_KEY = C419PC8HGZ6ZA7V3K41A9YRWTDMD3XDYCB