# Gradle.properties is not being read

**URL:** <https://discuss.gradle.org/t/gradle-properties-is-not-being-read/47991>\
**Category:** Help/Discuss\
**Created:** [March 18, 2024, 2:39pm UTC](https://discuss.gradle.org/t/gradle-properties-is-not-being-read/47991 "2024-03-18T14:39:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![gradleuser111](https://avatars.discourse-cdn.com/v4/letter/g/e56c9b/32.png) [@gradleuser111](https://discuss.gradle.org/u/gradleuser111)\
**Post date:** [March 18, 2024, 2:39pm UTC](https://discuss.gradle.org/t/gradle-properties-is-not-being-read/47991/1 "2024-03-18T14:39:25Z")

</div>

I have recently moved to a new laptop and is facing issue with setting up gradle 7.6.4 on intellij. I had no issues with the setup in my old laptop. I have gradle.properties file in C:\Users\username\ .gradle with artifactory\_user=user  
artifactory\_password=pass  
artifactory\_contextUrl=url  
From intellij when i import an existing gradle project it gives me error ,  
Could not get unknown property ‘artifactoryUser’ for settings ‘projectname’ of type org.gradle.initialization.DefaultSettings.

I tried hardcoding the username and password. Then it fails in the first line of build.gradle where it is unable to download plugin. I believe something is wrong with the initialization of gradle. I am using correct java version. I tried accessing properties and it returns null  
println(settings.hasProperty(‘artifactory\_password’) ? settings.artifactory\_password : ‘’)  
println(hasProperty(‘artifactory\_user’) ? artifactory\_user : ‘’)

---

<div class="post-metadata">

**Author:** ![oleosterhagen](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/oleosterhagen/32/11914_2.png) [@oleosterhagen](https://discuss.gradle.org/u/oleosterhagen)\
**Post date:** [March 23, 2024, 11:45am UTC](https://discuss.gradle.org/t/gradle-properties-is-not-being-read/47991/2 "2024-03-23T11:45:08Z")

</div>

Please compare the spelling of the property names in `C:\Users\username\ .gradle\gradle.properties` with your `settings.gradle`.

In the `gradle.properties` you use _snake case_, e.g. **artifactory\_user**. From the error message it seems you are using _camel case_ in your settings file:

> […] unknown property ‘ **artifactoryUser** ’ […]

---

<div class="post-metadata">

**Author:** ![gradleuser111](https://avatars.discourse-cdn.com/v4/letter/g/e56c9b/32.png) [@gradleuser111](https://discuss.gradle.org/u/gradleuser111)\
**Post date:** [March 24, 2024, 1:21pm UTC](https://discuss.gradle.org/t/gradle-properties-is-not-being-read/47991/3 "2024-03-24T13:21:55Z")

</div>

Apologies for the confusion. I am using same names at the same time. I just tried both camel and snake case. When i copied the error it happened to not match. I still have same issue even with same property name.
