w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
.gitignore is refusing to ignore a folder
All entries in .gitignore prevent git from listing untracked files when you type git status. That doesn't mean you can't add or commit them. In fact, you can. Tracked files will stay tracked even if they get added into .gitignore. So, in order to make them disappear from your repository, you will need to untrack them. To do that, you need to delete them (or at least make git think so): git rm -r --cached var If you type git status you will see that git now thinks you have deleted all the files in var. Commit that. After that, git status will tell you that you have a bunch of untracked files in var. That is, because the files weren't actually deleted, you only made git think so. Now add the folder to your .gitignore and they should be ignored.

Categories : GIT

Git .gitignore - Ignore Scripts folder in Visual Studio mvc project
The type of project is determined automatically by Github's Linguist gem. If you want to ignore those scripts on future commits (which you shouldn't do, if they are necessary to your project), your .gitignore file should read like this: Chat/Scripts/* It's also worth noting that even if you change this, unless you remove your scripts from the repository, Linguist will still note them when calculating the language used for the project.

Categories : Github

gitignore file ignore cachebusted files
Your ignore rule looks correct as long as that is the correct folder structure so my guess is that you are trying to ignore files which you were previously tracking changes on? Try running the following: git rm --cached public/min/* That should clear any tracked files within the min folder and from now on your .gitignore rule should work correctly.

Categories : GIT

SVN ignore like .gitignore
You can use svn:ignore .You generally need to tell the SVN to apply special properties to the files. svn propset svn:ignore "*.jpg" . [dot at the end of the command.] For multiple files you can add newline character. Type exactly like here with line breaks: svn propset svn:ignore "file1 file2 file3" dir1 Check that the files are ignored: svn status --no-ignore Then commit the code. And yes many duplicate questions are already available. You can refer my favorite svn cheatguide You can create a file svn-ignore.txt with your ignored files and directories. *.class *.jar *.war *.ear target/ .classpath .settings/ .project .metadata bin/ Now try following svn propset svn:ignore -RF /root/svn-ignore.txt . [dot for current dir] -R for recursive Added a blog post for

Categories : Svn

TFS/Git extensions seems to ignore .gitignore
You say that you are using VS 2013? If so, you do not need the extra git tools. I don't have them installed on my VS 2013, can use TFS with GIT just fine, and I don't experience the issue with .gitignore being ignored. You can even manage the .gitignore via the IDE GUI so formatting should always be in the format desired by TFS/VS: http://msdn.microsoft.com/en-us/library/vstudio/hh967655.aspx#ignore As stated in the Requirements from: https://visualstudiogallery.msdn.microsoft.com/abafc7d6-dcaa-40f4-8a5e-d6724bdb980c: Note: Visual Studio 2013 includes Git tools by default so these tools are not needed. Learn more on MSDN: http://msdn.microsoft.com/en-us/library/vstudio/hh850437.aspx

Categories : GIT

Ignore everything but specific directories using .gitignore
I have tried these three ignore paths in a local test repo: /src/BankBundle/Resources/public/example.html /src/* !/src/BankBundle In /src/BankBundle, there is a file hello.txt. When I run git add . and git status, the example.html file is ignored, but hello.txt is added. So it looks like your .gitignore file is set up correctly.

Categories : GIT

.gitignore NuGet packages folder at any level but include .targets file at any level
There is no 'good' way to do it (see manpage as a proof), however there is a hack around it. Main issue with ignoring packages/ of the bat is that git does not even check it's subdirectories due to directory being ignored. Solution here - you will have to have 2 gitignore files. One regular, and one inside the packages directory that looks like this: # ignore all files * # do not ignore directories !*/ # do not ignore targets !*.targets # do not ignore gitignore !*.gitignore New example: $ mkdir foo $ cd foo/ $ mkdir foo $ mkdir foo/bar $ mkdir foo/bar/baz $ touch foo/.foo $ touch foo/bar/.foo $ touch foo/bar/baz/.foo $ touch regular.txt $ touch foo/ignored.txt $ touch foo/bar/baz/ignored-2.txt $ cat foo/.gitignore * !*/ !*.foo !regular.txt !.gitignore $ git add . && git stat

Categories : Windows

Git diff doesn't ignore specified files in .gitignore
Okay, This is what you did wrong. Git will continue to track those files because you already started tracking them earlier in your project. At some point earlier did you run an initial commit that looked like: git add . # this added everything to the tracking system including your .test files git commit -a -m 'I just committed everything in my project .test files included' Putting things is your gitignore file will keep future files that you create which end in .test from entering your project, but you need to remove the .test files you already told git to track from git's memory. Pulling things in gitignore does not preform any action for already tracked files. What you need to do now is this: Option 1: # you can remove the files from gits tracking system and then put them back # whe

Categories : GIT

Using IntelliJ IDEA ignoring unversioned files aren't added to .gitignore
Git has its standard mechanisms to ignore files, basically: Patterns read from a .gitignore file in the same directory or in any parent directory. Patterns read from $GIT_DIR/info/exclude. Patterns read from the file specified by the configuration variable "core.excludesFile". IntelliJ, however, adds its own mechanism to ignore files: Window "Version Control", Tab "Local Changes", Button "Configure Ignored Files" (on the left). IntelliJ simply never performs a "git add" for files ignored in that way. Note that this is NOT the same as Git's "gitignore". The effect inside IntelliJ is the same, but it is not very transparent what is going on - as mentioned in the IDEA issue linked in the comment by CrazyCoder. On the Git command line a "git status" will show the "IntelliJ-ignored files"

Categories : GIT

What's a good filepath to force .gitignore not to ignore dlls in package folders?
Avoid versioning binary files in Git Why don't you want to ignore DLLs, period? Git isn't well-suited for versioning binary files, because it has to keep entire copies of each version every time they change, which causes the repos to become larger in size over time, which makes them harder to clone, and probably slows down other Git operations too. In addition, remote repo hosts like GitHub may have a limit on how big your repo can be. GitHub's current limit is 1 Gigabyte (emphasis mine): For best performance, we recommend repositories be kept under 1GB each. This limit is easy to stay within if large files (typically, binaries) are kept out of the repository. If your repository exceeds 1GB, you might receive a polite email from support requesting that you reduce the size of the repo

Categories : GIT

How to Ignore route for a specific View folder or a sepecific cshtml file in ASP.NET MVC 4
You'll need to add an entry in your web.config. Check the appSettings section add this (or update) <add key="webpages:Enabled" value="true" /> The entry is probably there already, so just update the value from false to true. They are 2 web.config files though .. one in the root of your app and another in the views folder .. you may need to add/update the entry on both. The default value (false) prevents *.cshtml and *.vbhtml files from being accessed directly from the browser.

Categories : Asp Net Mvc

.gitignore all the .DS_Store files in every folder and subfolder
I think the problem you're having is that in some earlier commit, you've accidentally added .DS_Store files to the repository. Of course, once a file is tracked in your repository, it will continue to be tracked even if it matches an entry in an applicable .gitignore file. You have to manually remove the .DS_Store files that were added to your repository. You can use git rm --cached .DS_Store. Once removed, git should ignore it. You should only need the following line in your root .gitignore file: .DS_Store. Don't forget the period! Felt tip: since you probably never want to include .DS_Store files, make a global rule. First, make a global .gitignore file somewhere, e.g. echo .DS_Store > ~/.gitignore_global. Now tell git to use it for all repositories: git config --global core.

Categories : Misc

how to make git find my files in the library folder, not ignored by gitignore?
I deleted the file. git, and make a new git init followed by git remote add origin https://github.com/ .... git add. && gitignore git add. && Git commit-a-m "go" && git push and it worked...

Categories : GIT

How To Switch Branches With Changes Made In A Folder That Was Added To .gitignore?
Looks like you've already committed those files before you added the rule to .gitignore. You can remove them from Git with git rm --cached <file>. In order to switch branches with a dirty directory, generally the fastest and easiest is to stash the changes.

Categories : GIT

Why git don't ignore contents of surefire-reports folder in maven target folder?
If those files have previously been checked in to git, git will still pay attention to them even though they otherwise meet the criteria for ignoring. Since they have been modified, we know that they have been previously checked in. See here: Making git "forget" about a file that *was* tracked but is now ".gitignored" and Ignoring an already checked-in directory's contents? Short answer: this will do the job and not delete the file locally: git rm -r --cached <your directory>

Categories : GIT

When building deb files using dpkg, I can't get it to ignore hidden files such as .git and .gitignore
I ended up placing my package root in a subdirectory and creating a build script at the root that created all the empty directories I needed, so I wouldn't need .gitignore files and the .git file would no longer get packaged.

Categories : Ubuntu

Correctly ignore all files recursively under a specific folder except for a specific file type
The best answer is to add a Resources/.gitignore file under Resources containing: # Ignore any file in this directory except for this file and *.foo files * !/.gitignore !*.foo If you are unwilling or unable to add that .gitignore file, there is an inelegant solution: # Ignore any file but *.foo under Resources. Update this if we add deeper directories Resources/* !Resources/*/ !Resources/*.foo Resources/*/* !Resources/*/*/ !Resources/*/*.foo Resources/*/*/* !Resources/*/*/*/ !Resources/*/*/*.foo Resources/*/*/*/* !Resources/*/*/*/*/ !Resources/*/*/*/*.foo You will need to edit that pattern if you add directories deeper than specified.

Categories : GIT

Intellij Idea lib folder export
Problem is by default android modulle looks for the reference libraries under the lib folder of the particular module itself. I resolved this by changing Native libs directory from the module lib to the root lib. It works fine now. Attached the screenshot for reference

Categories : Java

Creating a project from a folder in IntelliJ Idea 12
Import Project, select the directory with the existing sources (or its parent that you want to be the project root), follow the wizard steps. More details can be found in online help.

Categories : Intellij Idea

'!' does not exclude file in .gitignore
Replace temp with: temp/* This ignores all files in the directory. In most cases temp, temp/ and temp/* all work the same because in the first two cases, the directory is ignore while in the third case, Git does not track empty directories. Thus, the directory itself will be ignored. To illustrate this, this is essentially what happens when temp/ has temp1.txt temp2.txt temp3.txt: temp # anything with the name of "temp"; a directory, a symlink, a file. temp/ # whole of temp dir temp/* # temp/temp1.txt temp/temp2.txt temp/temp3.txt Thus, the third case will work in your case. The negation pattern must be placed after the pattern that covers it. In this case, !temp/script.txt must come after temp/*. Otherwise, it will not be applied. So, your final .gitignore file should look like

Categories : GIT

How to use Git Ignore on a self-emptying folder
It is enough to create the .gitignore file into your Main directory and write inside that file the entries of the directories you want to exclude. For example, type in your terminal cd Main && echo "Build/" >> .gitignore (if you are using Linux). Read this for other information: http://git-scm.com/book/en/Git-Basics-Recording-Changes-to-the-Repository#Ignoring-Files

Categories : GIT

updating gitignore file from egit in Mac
If you add those files to .gitignore, you need also to remove them from the index. git rm --cached afile git commit -m " remove afile" See "Eclipse Git plugin - remove file from repo without deleting local" to see how to do it in Egit, without the console (even though the CLI -- command-ilne interface) remains the safest way to do it) Team > Untrack Then and only then the .gitignore will be in effect.

Categories : Eclipse

Git, ignore folder except for some files with certain extension
Hmm. I don't think it's possible using direct .gitignore rules. However, this should help: .gitignore: packages/ add patterns files: git add --force -- $(find packages/ -type f -iname '*.targets') You could even make the add into a pre-commit hook to make this automatically pick up new targets files when they appear. To properly support filenames with special characters: find packages/ -type f -iname '*.targets' -exec git add --force -- {} +

Categories : GIT

Ignore containing folder, but not a folder within
How about this: # Ignore everything in the top-most directory /* # Except the wp-includes directory !wp-includes/ # Exclude everything in the wp-includes directory wp-includes/* # Except the folders themes and modules !wp-includes/themes/ !wp-includes/modules/

Categories : Wordpress

how to re-create .gitignore file after accidental removal
The .gitignore file is no different than any other file under version control. If you would like to get it back from HEAD, just do (wherever it was) git checkout -- .gitignore If you have deleted the file before adding it to the index or committing it, it is unfortunately lost and you'll have to recreate it (using your favorite text editor).

Categories : GIT

git: Cannot merge a file due to unknown .gitignore rules
If you want to force a merge to a particular branch see this question Regarding the gitignore file, what does the following give? git config --get core.excludesfile Is Installers in there?

Categories : GIT

EGit and Eclipse modifies .gitignore file but it should not
By default, EGit automatically adds resources marked as "Derived" to .gitignore. A typical example is the bin folder in a Java project containing the compiled classes. You can disable this by going to the preferences Team > Git > Projects and deselect "Automatically ignore derived resources by adding them to .gitignore". There was also a bug in EGit where it added entries when the Eclipse model and the filesystem were out-of-sync, see bug 421610 (fixed for EGit 3.5).

Categories : Eclipse

.gitignore file for java eclipse project
You need to add your source files with git add or the GUI equivalent so that Git will begin tracking them. Use git status to see what Git thinks about the files in any given directory.

Categories : Eclipse

SVN Don't Ignore dlls in "External References" folder
You need to set special SVN property for those directories where you need to ignore these files. In directories where you need to ignore all .dll files - use this extension. In directories where some files need to be ignored - use their names. To ignore all .dll files within the current folder: svn propset svn:ignore '*.dll' . To ignore some .dll files within the current folder fill the text file and apply: echo a1.dll > svnignore.txt echo a2.dll >> svnignore.txt svn propset svn:ignore -F svnignore.txt . And after that don't forget to commit changes: svn commit -m "Ignore some .dll" Note that it will clear all previous svn:ignore properties set for these folders if any (in this case you should use svn propedit). If you have a lot of folders on the same level as "Externa

Categories : Svn

How to ignore XML warnings from a specific folder in Eclipse?
open the Preferences (Windoww > Preferences) go to xml validation XML > XML Files > Validation set "No grammar specified" to Ignore Edit: I see you want it for a specific folder... but I'm afraid this only works on workspace or at least project level

Categories : Java

Can't ignore target folder by Tortoise SVN client
See TortoiseSVN Manual, especially this part: "Ignore files which are already versioned". When you run "Unversion and add to ignore list" command it will schedule the file or a folder to be removed on next commit and will add it to ignore list. You need to commit this change to repository. If the files are already in the repository, they have to be deleted from the repository and added to the ignore list. Fortunately TortoiseSVN has a convenient shortcut for doing this. TortoiseSVN → Unversion and add to ignore list will first mark the file/folder for deletion from the repository, keeping the local copy. It also adds this item to the ignore list so that it will not be added back into Subversion again by mistake. Once this is done you just need to commit the parent fol

Categories : Svn

Why is git still tracking files with extensions already added to .gitignore file
If the file already exists, you need to force-delete it: git rm --cached foo.pyc for every file already tracked. Commit, push, and profit. The file will remain ignored but in the working directory.

Categories : GIT

Gitignore exclusion for all appearances of a file throughout a directory tree
Is there a chance you need to update to the latest version? According to the website, **/ patterns were only supported from 1.8.2 onward.

Categories : GIT

Can I ignore build folder from master branch? - Yeoman Deployments using Git Subtree
.gitignore files do not remove existing files from the repository, and do not prevent you from committing files that are ignored. If you ignore files after they are committed, they will stay in your repository untouched, though changes to them will be ignored. If you want to commit changes to an ignored file (or a file that was committed and then ignored), you can use git add -f to forcibly add the ignored changes. To answer your question more directly, I have a feeling that git subtree will be okay with you deleting the files after you push the subtree. Also, you should be able to run git checkout gh-pages to grab the gh-pages branch for updating your deploy. Alternate method: The page you linked to has a link to a git directory deploy script that you may find useful.

Categories : GIT

How to copy a file to application folder in set up project during insatllation. File is in set up folder
If I'm understanding you correctly, this might solve your problem, or at least get you started: Include the file in the main project (for instance in a folder called "resources"). Right click the file in VS, choose properties, and set Copy to output directory to Coppy Always.

Categories : C#

How to monitor specific folder and save content of each log file in that folder to mysql database
First of all, congratulations! You are in front of a beautiful problem. My suggestion is to use divide and conquer. Here are my considerations: Put the relevant folder(s) under version control (for example, GIT) Check via GIT commands the files that changed every X amount of time. Also obtain the differences between the prior version of each file, and the new ones, so you can update your database parsing the new info. Just in case, here are ways to call system commands from ruby. Hope that helps,

Categories : Mysql

Is it good idea to have parallel processes which append txt file using async fs.appendFile(file, text, callback)
I think you are definitely going to hit data corruption and write lock issues there. Consider either using a real database instead of the filesystem or at the very least give each worker it's own file.

Categories : Node Js

RegEx to rewrite a multi-folder path and file name with unknown and varying folder depth
If you want to handle up to three levels you could use something like: RewriteRule ^ImageFolio4_files/1/([^/]+)/((?!AM|tn_|_cat)[^./]+.jpg)$ /ImageFolio4_files/cache/images/~$1~$2 [L,R=302,NC] RewriteRule ^ImageFolio4_files/1/([^/]+)/([^/]+)/((?!AM|tn_|_cat)[^./]+.jpg)$ /ImageFolio4_files/cache/images/~$1~$2~$3 [L,R=302,NC] RewriteRule ^ImageFolio4_files/1/([^/]+)/([^/]+)/([^/]+)/((?!AM|tn_|_cat)[^./]+.jpg)$ /ImageFolio4_files/cache/images/~$1~$2~$3~$4 [L,R=302,NC] Note the change of the expression for the file name: [^./]+ instead of [^.]+ so that it doesn't match any additional subfolders.

Categories : Regex

WiX: Copy a file from local folder to installation folder
Actually I've figured out what the issue is. The problem is that the SourceDirectory of the CopyFile element supposed to point to the Directory tag id. Instead, I've used SourceProperty attribute of the CopyFlie tag, and also defined a Property separately, which made the use of the CopyFile element correct. So it worked.

Categories : Wix

Does setting "idea.jars.nocopy" in idea.properites have any negative impact?
This will reduce the disk usage, but the locking can occur (you will not be able to replace the jar files in the project when the application or IntelliJ IDEA is running). If you don't plan replacing the jars and locking doesn't break your workflow, feel free to set this option to true. Mac/Linux users do not have the locking issue, it's Windows specific.

Categories : Maven



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.