Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Posts by Iizuki
With the --delete option of git-push: $ git push <remote-name> --delete <branch-name> For example: $ git push origin --delete my-branch
There's no point. It just causes unnecessary clutter and confusion. The correct way is to configure a manual way for triggering the CI/CD pipeline. In most systems there should be an API endpoint ...
Git's interactive mode has a patch action. This is the shortcut for it: git add --patch <file> It will split the file into hunks and interactively ask which one's to add. It has a plethor...
How to move the main branch back to an earlier commit in git?
With git reset, but first, you may want to save the current state in another branch: $ git switch main $ git branch backup-of-main Now the (perhaps messed up) state is safely stored in branch ...
Say I've made a bunch of changes to a file and would like to split those changes into two or more commits. Normal git add however stages the whole file in one go. So how to add only some of the ch...
What are the differences between git apply and git am commands? Both seem to be used for applying patches to repositories. When should one be used over the other?
Global variables make the code hard to reason about This is especially visible when debugging. Say you have a function which errors. The stacktrace tells you where the function got it's arguments,...
In git you can put your current changes aside for a moment with git stash. This is really neat but what often ends up happening is that you forget what was in there, and what was the state of the b...
Well it was easier than I thought: git diff stash A note about the direction: This will show things which are present in the working directory but not present in the stash as added +. And vice ...
How to delete a branch from a remote in git? E.g. maybe you had this branch locally too, but you deleted it already according to this question. Now you want to get rid of the corresponding remote ...
The default port is 3306. MariaDB is a fork of MySQL, and this is the default port for MySQL as well. Source.
The safe way: [1] git branch --delete <branch-name> It will fail if the branch isn't merged. If this is ok then you can delete it anyway like this: [2] git branch --delete --force <br...
By default Gitlab CI jobs run on any commit. I would like to restrict some of them to run only on commits to specific branches. How to do this in .gitlab-ci.yml?
Haskell tooling can be confusing. Both Stack and Cabal appear to be build tools with similar goals. How do they differ? Why should you pick one over the other?
Compare $CI_COMMIT_BRANCH to your desired branch name in rules: # .gitlab-ci.yml stages: - test - deploy # This job will run always. test-job: stage: test image: bash script:...
They are not a part of git the way .gitignore files are. It's just a convention to add empty directories to git repositories. Normally git ignores empty directories altogether. Adding an empty fil...
Types are often followed by exclamation marks in GraphQL schemas. What do they mean? type User { id: Int! email: String! name: String! updatedAt: String! createdAt: String...
It's a type modifier that means that the field is non-nullable. That is, when uploading these types you must provide values for these fields, and in turn the server promises to always populate the...
What would be the simplest (and most lightweight) way of getting email notifications of failures in kubernetes clusters. Mostly interested in failing pods, so notifying on certain kubernetes event ...
You can separate the curly brackets with spaces, and instruct jinja to remove them afterwards: { {{- jinja_expression -}} }. That way the outer curly brackets are left untouched. The minus signs s...
Specify your arguments after --: cargo run --offline -- --my-argument 42 --offline is just an example of cargo's own argument. They are passed before --. --my-argument and 42 will be passed to...
When developing a rust program you build and run using cargo run. However you cannot just append arguments to that as they will be caught (and likely rejected) by cargo itself. So how to pass argum...
You're very much on the right track. std::iter::FromIterator trait This trait is indeed what makes it work. In particular, both functions' return types implement the trait: std::result::Result&l...
Add the following to /etc/containers/registries.conf: unqualified-search-registries = ["docker.io"] [[registry]] location = "docker.io" Now you can pull just like you would in docker: podm...