Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9160881
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T13:50:32+00:00 2026-06-17T13:50:32+00:00

I have a gitignore that only sends two subdirectories to github. my gitignore /*

  • 0

I have a gitignore that only sends two subdirectories to github.

my gitignore

/*
!/conf
/conf/*
!/conf/jingle_profiles
!/conf/dialplan

this uploads the two subdirectories (dialplan,jingle_profiles) to github.

I want to clone those subdirectories into the root file tree (/usr/local/freeswitch) and have them keep those two subdirectories synced without deleting everything else.

edit:

the error I get when I:

sudo git clone https://github.com/dgmcguire/freeswitch.git

is

fatal: destination path 'freeswitch' already exists and is not an empty directory.
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T13:50:33+00:00Added an answer on June 17, 2026 at 1:50 pm

    git clone requires an empty directory, but subsequent pulls won’t do anything to ignored files.

    So, simply create an empty subdirectory inside /usr/local/freeswitch, do your git clone inside that subdirectory and afterwards, move the contents of this subdirectory to /usr/local/freeswitch.

    Should be something like this:

    mkdir /usr/local/freeswitch/git_tmp
    cd /usr/local/freeswitch/git_tmp
    git clone https://github.com/dgmcguire/freeswitch.git
    mv /usr/local/freeswitch/git_tmp/* /usr/local/freeswitch/
    rm -r -d /usr/local/freeswitch/git_tmp
    

    I am no linux guy, so there might be some errors in the commands used – the intent however should be clear.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have some files that I want to be ignored via git pull on
I have a directory structure like this: .git/ .gitignore main/ ... tools/ ... ...
I have an already initialized Git repository that I added a .gitignore file to.
I have local changes to a file that I don't want to commit to
I have a git repository that's used only to hold graphics and sound files
Obviously this is a common issue: we have PHP web applications that are managed
I have a simple Jenkins build that pulls down my project from github, builds
After reading several questions about .gitignore I have found no one that could answer
I have editor settings that I want to spread in all repositories. If the
I have a git clone of a C project, and on that i have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.