Hey,
Following https://github.com/saltstack/salt/pull/49167, when I set a file.directory state, the directory is created in lowercase and not the case I have specified. Windows is case insensitive so it is not breaking applications, but it would be nice to have my case kept.
abcdef:
file.directory:
- name: C:\AbcDef\GhIJ
- makedirs: True
C:\abcdef\ghij folder is created
C:\AbcDef\GhIJ is created
I am running 2018.3.3 masterless salt minion with the following versions:
C:\salt>salt-call --versions
Salt Version:
Salt: 2018.3.3
Dependency Versions:
cffi: 1.10.0
cherrypy: 10.2.1
dateutil: 2.6.1
docker-py: Not Installed
gitdb: 2.0.5
gitpython: 2.1.3
ioflo: Not Installed
Jinja2: 2.9.6
libgit2: Not Installed
libnacl: 1.6.1
M2Crypto: Not Installed
Mako: 1.0.6
msgpack-pure: Not Installed
msgpack-python: 0.4.8
mysql-python: Not Installed
pycparser: 2.17
pycrypto: 2.6.1
pycryptodome: Not Installed
pygit2: Not Installed
Python: 2.7.14 (v2.7.14:84471935ed, Sep 16 2017, 20:25:58) [MSC v.1500 64 bit (AMD64)]
python-gnupg: 0.4.1
PyYAML: 3.12
PyZMQ: 16.0.3
RAET: Not Installed
smmap: 2.0.5
timelib: 0.2.4
Tornado: 4.5.1
ZMQ: 4.1.6
System Versions:
dist:
locale: cp1252
machine: AMD64
release: 2016Server
system: Windows
version: 2016Server 10.0.14393 Multiprocessor Free
@dan-rus Thanks for pointing this out. I agree it would be nice to preserve the case specified by the state.
@dwoz, no it should NOT just "be nice". It's the same as #45409. If the user specifies a path in whatever casing, she might do this for a reason. It's not Salt's task to question this and change the casing at will. That's a bug which should be fixed ASAP, NOT a feature.
Any news on this? It's still annoying. And can it be changed to a bug, please?
I am also facing this issue with file.managed on Windows. Do we have an update on this issue when will it be fixed?
+1 from me. Camelcase exists for a reason, and file.managed should not change input data.
+1 for preserving case. I think this issue is causing file.recurse to delete portions of a CAD configuration that we use saltstack to manage on Windows clients. We don't prepare the configuration, so we can't stop the input from being mixed case.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.
Reopening. Now can this be finalised, please? It's still a no-go.
Thank you for updating this issue. It is no longer marked as stale.
Most helpful comment
@dwoz, no it should NOT just "be nice". It's the same as #45409. If the user specifies a path in whatever casing, she might do this for a reason. It's not Salt's task to question this and change the casing at will. That's a bug which should be fixed ASAP, NOT a feature.