Folder in Git is split - gitlab

I have a folder called 'Development' with subfolders 'a' and 'b' in my Pycharm project. However, when I look at the folder structure in Gitlab with the browser, the folder is split into "Development" (Capital initial letter) with subfolder "a" and "development" (small initial letter) with subfolder "b". I tried to merge the folders in Gitlab using checkout main and push into main. But that didn't change anything and when I'm in the main branch with the Pycharm IDE, I can only see the folder 'Development' with the two subfolders 'a' and 'b'.
In Pycharm:
Project/
Development/
a/
b/
In Gitlab:
Project/
Development/
a/
development/
b/
This structure was created automatically in Git. I never created it this way.
How can I merge the two folders in the Gitlab repository?

Related

groovy programming and git commit

I am stuck with this problem.
I have a list of files inside a folder which is inside another folder in github. The goal is to open all the folder and read the files inside each of those folders with the latest git commit.
Please help.
FOLDER1
--- Folder a
------ file a1
------ file a2
--- Folder b
------- file b1
------- file b2
I want to iterate all folders inside Folder1 and read contents of file with the latest commit ID in each sub-folder.

List files in a folder, in the parent directory

I know you can list the files of a directory with:
os.listdir('FOLDER_DIR')
But how do i list the files in a folder that exists in a directory above where i am right now?
For example, consider the following folder structure:
----PARENT
-------sub_dir1
-------sub_dir2
If my python program is in sub_dir2, how can i list the contents of folder sub_dir1, without changing directory?
The answer is os.listdir('../sub_dir1')

Moving Git to another folder, but I've got a problem

My git was init in folder ~/ryan/pythonproject/ and then later on I started using PyCharm and it created a venv for the project after importing. So now I have:
~/ryan/pythonproject/venv/
The first directory has my original work on the project, and then it appears I have a duplicate of my work under the venv folder.
Whenever I commit/add/push it does the original folder as well as the venv folder.
What I would like to do is have Git stop monitoring the original folder and only have git under the venv folder only. What's the best way to do that?
If you want to stop monitoring a folder you can put it to the .gitignore file. So i.e. you have:
YourProject/venv/FolderA
YourProject/venv/FolderB
YourProject/FolderA
YourProject/FolderB
Then just add the lower two to the .gitignore .
But please think about it whether this is really what you want. Usually it is the other way around. Keep your files and ignore the build folder.

Gitkraken revert deleted files

Currently, I am using GitKraken to upload my files to Gitlab. However, there was a submodule that contained all my files for the project - in an attempt to combine the submodule into the main respiratory, I tried deleting it; however, my entire submodule is gone now. When I go into the trash folder of my Mac, I can see the folder except it is named with extra letters and contains files such as Build and Test Index. Is there anyway to get this submodule back?
UPDATE: I tried reverting the files from the trash folder, but it only put the files back into the derived data folder. Not sure how to get the submodule back, it is asking to initialize it by specifying a URL.

Working with two repos and two projects in Git

I'm new to Git, and i want to push some files to one repo and other files to another repo, but when i do the second push it goes with the files of the first repo. How can i push the the files separately?
Should you have .git directories in each your project directories. And don't forget for use git bash inside directories what you want to push. Example:
Project A in
C:/projectA
inside projectA you have .git directories(hidden files)
Project B in
C:/projectB
inside projectB you have .git directories(hidden files)
for push project A, try this
cd c:
cd projectA
you stay in projectA, and then push.

Resources