The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,927 other followers

Archive for the ‘Source Code Management’ Category

How to move Git submodule to sub-directory? – Stack Overflow

Posted by jpluimers on 2020/05/26

It’s a few steps as per [WayBackHow to move Git submodule to sub-directory? – Stack Overflow, so I’m not sure it is the best solution, but it at least works (thanks Philzen):

Had the same problem just the moment ago and ended up deleting the submodule reference (as outlined in this article) and recreating it where i wanted it to go.

To follow your example of moving submodule jquery into repos/jquery

  1. Delete the (typically three lines) submodule reference from .gitmodules.
  2. Check .git/config for references to the submodule and remove them, if existent
  3. do git rm --cached jquery to cut the submodule reference out of the repository
  4. remove the old submodule folder
  5. recreate you submodule reference (as you possibly did before) with git submodule add git://github.com/jquery/jquery.git repos/jquery

In case your submodule was set to specific tag, respectively commit (which you’ll surely have in a stable project) you will have set it again.

Due to this complex process i am strongly hoping there is (or will be, at least on the git roadmap) a more straightforward way of achieving this. If not, surely some scripts could be fumbled together to do this quicker…

References:

–jeroen

Posted in Development, DVCS - Distributed Version Control, git, Software Development, Source Code Management | Leave a Comment »

version control – How do I do an initial push to a remote repository with Git? – Stack Overflow

Posted by jpluimers on 2020/04/30

Based on [WayBack] version control – How do I do an initial push to a remote repository with Git? – Stack Overflow, this is what I do:

On the server

mkdir my_project.git
cd my_project.git
git --bare init

On the client

mkdir my_project
cd my_project
touch .gitignore
git init
git add . git
commit -m "Initial commit"
git remote add origin youruser@yourserver.com:/path/to/my_project.git
git push --set-upstream origin master

The last one is important, especially when you have multiple remotes.

Some servers allow you to skip the server part, as they run them automatically when pushing a new repository from the client.

This can be both an advantage and a disadvantage, for instance when you have typos when adding the remote.

–jeroen

Posted in Development, DVCS - Distributed Version Control, git, Software Development, Source Code Management | Leave a Comment »

Mono-repo or multi-repo? Why choose one, when you can have both?

Posted by jpluimers on 2020/04/29

Interesting: [WayBack] Mono-repo or multi-repo? Why choose one, when you can have both?

Uses: [WayBack] GitHub – mateodelnorte/meta: tool for turning many repos into a meta repo. why choose many repos or a monolithic repo, when you can have both with a meta repo?

–jeroen

Posted in Development, DVCS - Distributed Version Control, git, Software Development, Source Code Management | Leave a Comment »

Binary search for finding problematic versions: install a specific version in homebrew and git bisect

Posted by jpluimers on 2020/04/14

I’ve used these excellent posts to find out which youtube-dl version started to exhibit troublesome NPO downloads, then later find the actual failing commit:

Why the effort? I needed an as recent as possible youtube-dl working on as many sites as possible because of some work preparation.

The first link is very important because brew versions and alternatives have stopped working some 6 years ago, even though they turn up high on Google searches for brew install specific version. Hence the quote from the first link:

Installing software packages on Mac is very easy with homebrew. You typically get the latest version, however often in production you do not have the latest version of a software package. Another use case is when you upgrade to the latest and you find out there is bug which blocks you doing something. In this case you would like to downgrade to the previous version until the bug is fixed.In both cases you need to install a specific version of a software package with homebrew on your Mac, which tends to be not that trivial. There is a lot of discussion about this on stackoverflow but some of them are outdated based on brew versions which is not available anymore.

Read the rest of this entry »

Posted in Apple, Conference Topics, Conferences, Development, DVCS - Distributed Version Control, Event, git, Home brew / homebrew, Power User, SocialMedia, Software Development, Source Code Management, YouTube | Leave a Comment »

Rendering SVG on gitea and gitlab

Posted by jpluimers on 2020/04/07

At the time of writing:

<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">

–jeroen

Posted in Development, DVCS - Distributed Version Control, git, gitea, GitHub, GitLab, Software Development, Source Code Management | Leave a Comment »

 
%d bloggers like this: