0

I have an Emacs Configuration in a repository and whenever I do git clone <repository> it creates for me a folder with the name of the repository and the configuration files inside

I would like it to only create "clone" the settings files instead of creating a folder with the files inside

  • Does this answer your question? [Clone contents of a GitHub repository (without the folder itself)](https://stackoverflow.com/questions/6224626/clone-contents-of-a-github-repository-without-the-folder-itself) – CreepyRaccoon Dec 21 '22 at 00:26

1 Answers1

0

I think there are 3 options:

  1. Download the files without cloning the repository
  2. Clone contents of a GitHub repository (without the folder itself):
    • git clone url . - works only if the current directory is empty
    • git init trick - (see the link)
  3. Configure Emacs to load the config file from a different location:

    replace your ~/.emacs.d/init.el with this:

    (setq user-emacs-directory "/path/to/git_repo/")
    (load "/path/to/git_repo/init.el")
    
tymtam
  • 31,798
  • 8
  • 86
  • 126