derekcresswell / drupalbaseproject
A base for a Drupal 9 site.
Installs: 8
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:project
Requires
- composer/installers: ^1.9
- drupal/admin_toolbar: ^2.3
- drupal/core-composer-scaffold: ^9
- drupal/core-recommended: ^9
- drush/drush: ^10
Requires (Dev)
- drupal/core-dev: ^9
Conflicts
This package is auto-updated.
Last update: 2024-11-25 12:44:35 UTC
README
This is a repository to get a jump start on creating a Drupal site.
Features
This template has base files for the following :
-
- This just has the bare essentials to avoid bloat.
- Drupal 9.x
- Drush 10
- Admin Toolbar
- This just has the bare essentials to avoid bloat.
-
- This is used to create the development containers and site.
- By default, this installs a :
- Apache appserver
- Mysql database
- Node service
- Mailhog server
- There is also tooling for :
- Drush
- Phpunit
- npm
-
- This is a list of frequent tasks that can be used to create, update, start, and stop the development site.
-
- This allows our themes to utilize SCSS in our theme as opposed to vanilla CSS.
-
Development settings (in
web/sites
)- The settings for a database connections and other development settings.
- If you use the automatic set up the file is used as local settings so, you will need to ensure the normal settings file includes the local ones.
Information on the technologies used here can be found in the technologies section.
Usage
You can copy this template three ways.
-
Fancy
- On GitHub, press the "Use this template" button.
-
Old school
- Clone the repo and run
rm -r path/to/repo/.git
.
- Clone the repo and run
-
Composer
- Using Composer, you can create a project with the command
composer create-project derekcresswell/drupalbaseproject
.
- Using Composer, you can create a project with the command
After you have the repo cloned follow these instructions to get your site set up :
-
Find and replace "SITE-NAME", "PROJECT-NAME", and "THEME-NAME" with the appropriate names.
- Also change the
name
at the top of the Lando file.
- Also change the
-
Navigate to the project root and run
inv setup
. This should start your site and set up things like settings.- In this file this is a skeleton command for updating the data base on your site. This will need to be filled in manually.
-
Navigate to
web/sites/default/settings.php
and all the way at the button uncomment the last three lines :
if (file_exists($app_root . '/' . $site_path . '/settings.local.php')) { include $app_root . '/' . $site_path . '/settings.local.php'; }
- Then you can go to
composer.json
and remove the top few lines (the lines above therepositories
key).- These lines contain information for Packagist and do not need to be used in a site.
Then navigate to the site using the links that lando has given you, site-name.lndo.site
, and finish the set up by following the installation instructions from Drupal.
This should give you a running Drupal site to work on.
Theme Set Up
For info on setting up a custom theme see the custom theme base.
Technologies
There are two main technologies used to make the development process a breeze. Installation instructions can be found on their respective websites.
-
Lando vastly simplifies local development and DevOps so you can focus on what's important; delivering value to your clients and customers.
-
Invoke is a Python (2.7 and 3.4+) task execution tool & library, drawing inspiration from various sources to arrive at a powerful & clean feature set.
These are the only two dependencies required to fully utilise this repository. Other technologies are used prominently though they are included within Lando.