developer resources
Codebales holds an ever growing number of solutions to problems that we have experienced in our day to day code writing
Selected filter
42
results
Andrew Fletcher
•
Maintaining a Drupal site is usually smooth sailing once the environment is properly set up. However, even in a stable environment, updates to modules can sometimes reveal underlying configuration issues that weren't apparent before. This was the case when I updated a contrib module on a Drupal 10.3 site, which suddenly started throwing errors related to the mbstring PHP extension.
The problem
The problem first surfaced after updating the search_api_attachments contrib module. The Drupal...
Andrew Fletcher
•
In our projects, team members frequently generate new Git branches linked to the...
Andrew Fletcher
•
git reset, git revert, and git cherry-pick are three Git commands used for...
Andrew Fletcher
•
Update Ubuntu 20.04
To begin update the server using the command
sudo apt update...
Andrew Fletcher
•
git clone git@bitbucket.org:{username}/{repo}.git
And I was unceremoniously...
Andrew Fletcher
•
Something I haven't had to do in a while is to change the name of a Git branch both local and remote.
Steps to renaming a branch
Rename your local branch:
If you are on the branch you want to rename:
git branch -m new-nameWhereas, if you're on a different branch:
git branch -m old-name new-nameDelete the old-name remote branch and push the new-name local branch:
git push origin :old-name new-nameReset the upstream branch for the new-name local branch:Switch to the branch and then:
git...
Andrew Fletcher
•
Git filename error when running the git add command. The error I'm...
Andrew Fletcher
•
Post creating a new branch in the repo, next step was to run the checkout...
Andrew Fletcher
•
I'm in an environment where the default branch is staging and I'm attempting to...
Andrew Fletcher
•
Installing PHP on OSX and it installed PHP 8.2.x. However, for my...
Andrew Fletcher
•
How do you remove a file from git?
Use the command (rm) to remove files from your local git repository
git rm --cachedIt's important to note the --cached flag deletes the file from your git repository, it becomes an untracked file in your project folder. For the change(s) to kick in, you need to commit the changes.
Andrew Fletcher
•
Moving a Git repo due to a change of agencies
Steps to change the...
Andrew Fletcher
•
Currently, I have a situation where I have two repositories. The first is...
Andrew Fletcher
•
JSON structure
Outlining the structure of the elements common attributes:...
Andrew Fletcher
•
In this instance, I'll check the beginning of the string. I want to focus...