Skip to content

liam-hales/terminal

Repository files navigation

Terminal

Terminal is a web app created to provide web-based developer tools with a dev-friendly terminal interface.

https://t.liamhales.dev


Docs 📑

⚠️ WARNING - Please make sure to follow the Getting Started section first to avoid running into any issues.



Built With 🛠️

This app was built and hosted with the following technologies. For a full list of dependencies used, see the package.json file.




Getting Started 🚀

  1. Download and install Node Version Manager
  2. Install and use a version of Node.js >= v24.13
$ nvm install 24.13
$ nvm use 24.13

$ node --version
v24.13.0

$ npm --version
v11.6.2
  1. Run corepack enable to enable Corepack
  2. You should now be able to use the yarn package manager which you MUST use for this project

📝 NOTE - Yarn comes bundled with Corepack and is the preferred way to install/manage Yarn. Check out the Yarn Installation Guide for more info

$ yarn --version
v4.12.0

📝 NOTE - The current version of Yarn should match the packageManager version in the package.json

  1. Run yarn in the project root
  2. Create a .env file in the project root
SITE_URL = 'https://t.liamhales.dev'

DYNAMO_DB_REGION = 'eu-west-2'
DYNAMO_DB_SHARED_BLOCKS_TABLE_NAME = 'terminal-shared-blocks'

FILE_STORE_ID = '******'
FILE_READ_WRITE_TOKEN = '******'


Local Development 👨🏻‍💻

For local development there are two ways to build and start the app depending on your specific needs...

Development Server

  1. Run yarn start:dev to start the development server
$ yarn start:dev

Production Server

  1. Run yarn build to build the app for production
  2. Run yarn start:prod to start the production server
$ yarn build
$ yarn start:prod


Production 🌍

Building

  1. Run yarn build to build the app for production
$ yarn build

Deploying

The app is hosted on AWS Amplify and is built and deployed using their GitHub integration and auto-build feature. When code is pushed to the repos main branch, a production build and deployment is triggered. No need to manually build or deploy.

$ git checkout main
$ git add --all
$ git commit -m "Fixed bugs"
$ git push

Bundle Analysing

Analysing a production bundle is done using @next/bundle-analyzer under the hood and is used to inspect the app and the size each page, component and dependency takes up within the bundle.

  1. Run yarn build:analyse to build and analyse the app for production
  2. Open the generated .html files located in .next/analyze
$ yarn build:analyse

⚠️ WARNING - The bundle analyser will automatically open the generated .html files in your default browser



Public Assets 🌆

Most public assets already exist in the /public directory, however some assets such as some of the icons are dynamically built using build scripts.

  1. Run yarn build:icons to build the favicon.ico and .webp icons
$ yarn build:icons

📝 NOTE - These public assets are not required for a functional build

📝 NOTE - Public assets such as the sitemap.xml and robots.txt files exists on dynamic routes



Dependency Management 📦

Managing dependencies is done using npm-check-updates under the hood which has the ability to check for new dependency versions and upgrade dependencies to a specified target version.

  1. Run yarn deps to list upgradable dependencies

Options

  • --target ${latest | minor | patch} to scope dependencies to a specific target version
  • --upgrade to upgrade dependencies
  • --interactive to choose which dependencies to upgrade in interactive mode

Check out the npm-check-updates docs or run yarn ncu --help for more info.

About

Web-based developer tools with a dev-friendly terminal interface.

Topics

Resources

Stars

Watchers

Forks

Contributors

Languages