Sublime Forum

Dot Files for Projects

#1

Hey guys, brand new here (first post), been using sublime text for a few months now and like it a lot. (moderators, feel free to move this post, if it should be in another category)

i just created a new project, to manage all my Home Assistant configuration files, seems to be working great for this; but I’ve got a few questions.

ST creates a dot file, for the project, in the root folder or the project, if I remember correctly. From what I’ve been reading, this is to store project specific configuration. Please correct me if I’m wrong…

More importantly, it also seems like ST creates a new dot file for every file I create in the project.

So if I add say “file.yaml” another file similar to “.file.yaml” is created (I’m not in front of my computer, so the naming might be different). I’ve currently added roughly 15 config (yaml) files, but have roughly 30 new files in total.
Can anyone tell me why that is? Is there any way of disabling this feature, seems quite excessive?

Also, if this can’t be disabled, can the dot files be stored somewhere other than my working directory, I’d rather keep that as clean as possible.

0 Likes

#2

ST does not create any file by itself, I guess you installed a plugin that does this.

0 Likes

#3

I’ll have to check when I get home, but I don’t recall installing any plugins. I just downloaded it from the site, applied a theme, and started using it.

0 Likes

#4

The only files sublime text creates when saving a project are one “.sublime-project” and one “.sublime-workspace” file, which aren’t even dotfiles since the project name before the extension is mandatory.

As mentioned, it does not create such files when saving at all.

0 Likes

#5

Thanks for the reply guys, let me show you what I’m talking about. Here’s an example listing of files in my project directory. (this is a Home Assistant config dir):

-rwxr--r--  1 hass hass      4096 Oct 31 18:01 ._hass.sublime-project
-rwxr--r--  1 hass hass       127 Nov  1 16:09 hass.sublime-project
-rwxr--r--  1 hass hass      4096 Oct 31 18:01 ._hass.sublime-workspace
-rwxr--r--  1 hass hass      9504 Nov  2 17:52 hass.sublime-workspace
-rwxr--r--  1 hass hass      4096 Oct 31 19:03 ._light.yaml
-rwxr--r--  1 hass hass        18 Oct 31 19:03 light.yaml
-rwxr--r--  1 hass hass      4096 Oct 31 19:17 ._notify.yaml
-rwxr--r--  1 hass hass       181 Oct 31 19:17 notify.yaml
-rw-r--r--  1 hass hass      1122 Nov  1 18:11 options.xml
-rwxr--r--  1 hass hass      4096 Nov  2 18:15 ._plants.yaml
-rwxr--r--  1 hass hass       652 Nov  2 18:14 plants.yaml
-rwxr--r--  1 hass hass      4096 Nov  1 19:11 ._scene.yaml
-rwxr--r--  1 hass hass        85 Nov  1 19:09 scene.yaml
drwxr-xr-x  2 hass hass      4096 Oct 31 18:52 scripts
-rwxr--r--  1 hass hass      2332 Nov  1 21:50 scripts.yaml
-rwxrw-r--  1 hass hass      1613 Nov  2 17:21 secrets.yaml
drwxr-xr-x  2 hass hass      4096 Nov  1 17:41 sensors
-rwxr--r--  1 hass hass      4096 Oct 31 18:18 ._sensors.yaml
-rw-rw-r--  1 hass hass      3012 Sep 27 17:47 themes.yaml
drwxr-xr-x  2 hass hass      4096 Sep 27 17:40 tts
-rwxr--r--  1 hass hass      4096 Oct 31 18:20 ._zones.yaml
-rwxr--r--  1 hass hass       230 Oct 31 19:09 zones.yaml
-rw-r--r--  1 hass hass       108 Nov  4 14:11 zwscene.xml

I’ve manually created all of the “filename.yaml” files, and as far as I can tell, sublime has created all of the “._filename.yaml” files. So the files in my working directory has basically doubled.

Any ideas how I can disable this?

0 Likes

#6

We all understood your problem already, but again: Sublime Text does not create such files. Even though no package/plugin creating such files seems known to the community, you might have one installed. Maybe any auto-backup package or a diff package using the dot files as snapshot to compare against?

2 Likes

#7

Thanks @deathaxe where would I go about checking for such packages?

0 Likes

#8

I’d start to disable packages one by one excluding themes/color schemes and starting with ones I’d think they might do so. It’s nasty but the only way to find it if you don’t have any idea of which one is causing it.

0 Likes

#9

I hate to sound like a noob, but how do I find and disable packages? I went digging around a bit and the “user packages” folder is empty.

0 Likes

#10

Most packages installed by Package Control live in the Data/Installed Packages folder. The easiest way to get there is by using

  1. Main Menu -> Preferences -> Browse Packages
  2. Move up one folder in the opened Explorer
  3. You should now see Installed Packages folder

The location of Data depends on your OS and setup.

The easiest way to disable packages is by using the command pallet command Package Control: Disable Package. As it lists all packages (installed and default ones), you might need to checkout the Installed Packages folder to see which one might be worth trying to disable.

0 Likes

#11

Thanks for the instructions. I’ve found the “Installed Packages” folder, and it’s empty.

0 Likes

#12

My guess is that you have some kind of backup software or something that’s creating those dotfiles.

0 Likes

#13

Running latest MacOS (10.13), with TimeMachine, no third party backup software installed.

A quick search for this shed a little light on the issue.

The post is a bit dated, and might not apply to current versions, but it’s a start. Anyone know if MacOS 10.13 supports resource forking?

What’s confusing me the most is, if I open the same directory in Atom, and create a new file, it doesn’t create (or at least display) the ._filename. It’s only in Sublime.

0 Likes

#14

What filesystem are you using?

0 Likes

#15

The project directory is a mounted SMB share from a linux box.

0 Likes

#16

Is it a valid resource fork? If so, what data is in it? (I admit that I haven’t cracked open a resource fork since the old days of ResEdit.)

0 Likes

#17

I’m fairly certain the issue is SMB.

0 Likes