-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Makefile location next to its name in files tree #867
Open
fan-tom
wants to merge
4
commits into
JetBrains:master
Choose a base branch
from
fan-tom:makefile-location
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
fun properties(key: String) = project.findProperty(key).toString() | ||
|
||
plugins { | ||
// Java support | ||
id("java") | ||
// Kotlin support | ||
id("org.jetbrains.kotlin.jvm") version "1.6.20" | ||
// gradle-intellij-plugin - read more: https://github.com/JetBrains/gradle-intellij-plugin | ||
id("org.jetbrains.intellij") version "1.5.2" | ||
// gradle-grammar-kit-plugin - read more: https://github.com/JetBrains/gradle-grammar-kit-plugin | ||
id("org.jetbrains.grammarkit") version "2021.2.2" | ||
} | ||
|
||
group = properties("pluginGroup") | ||
version = properties("pluginVersion") | ||
|
||
sourceSets["main"].java.srcDirs("src", "gen") | ||
sourceSets["main"].resources.srcDir("resources") | ||
sourceSets["test"].java.srcDirs("test") | ||
|
||
// Configure project's dependencies | ||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
dependencies { | ||
implementation(kotlin("stdlib-jdk8")) | ||
} | ||
|
||
// Configure gradle-intellij-plugin plugin. | ||
// Read more: https://github.com/JetBrains/gradle-intellij-plugin | ||
intellij { | ||
pluginName.set(properties("pluginName")) | ||
version.set(properties("platformVersion")) | ||
type.set(properties("platformType")) | ||
downloadSources.set(properties("platformDownloadSources").toBoolean()) | ||
updateSinceUntilBuild.set(true) | ||
|
||
// Plugin Dependencies. Uses `platformPlugins` property from the gradle.properties file. | ||
plugins.set(properties("platformPlugins").split(',').map(String::trim).filter(String::isNotEmpty)) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# IntelliJ Platform Artifacts Repositories | ||
# -> https://www.jetbrains.org/intellij/sdk/docs/reference_guide/intellij_artifacts.html | ||
|
||
pluginGroup = org.jetbrains | ||
pluginName = Makefile | ||
pluginVersion = 1.0-SNAPSHOT | ||
pluginSinceBuild = 212 | ||
pluginUntilBuild = 221.* | ||
# Plugin Verifier integration -> https://github.com/JetBrains/gradle-intellij-plugin#plugin-verifier-dsl | ||
# See https://jb.gg/intellij-platform-builds-list for available build versions | ||
pluginVerifierIdeVersions = 2022.1 | ||
|
||
platformType = IC | ||
platformVersion = 2022.1 | ||
platformDownloadSources = true | ||
# Plugin Dependencies -> https://www.jetbrains.org/intellij/sdk/docs/basics/plugin_structure/plugin_dependencies.html | ||
# Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22 | ||
platformPlugins = terminal | ||
|
||
# Opt-out flag for bundling Kotlin standard library. | ||
# See https://kotlinlang.org/docs/reference/using-gradle.html#dependency-on-the-standard-library for details. | ||
kotlin.stdlib.default.dependency = false |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-all.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
rootProject.name = "makefile" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 9 additions & 1 deletion
10
makefile/test/com/jetbrains/lang/makefile/MakefileTestUtils.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,16 @@ | ||
package com.jetbrains.lang.makefile | ||
|
||
import com.intellij.openapi.application.PathManager | ||
import java.io.File | ||
|
||
/** | ||
* Test data directory | ||
*/ | ||
internal val BASE_TEST_DATA_PATH: String = PathManager.getHomePath() + "/contrib/makefile/testData" | ||
internal val BASE_TEST_DATA_PATH: String = findTestDataPath() | ||
|
||
private fun findTestDataPath(): String { | ||
val f = File("testData") | ||
return if (f.exists()) { | ||
f.absolutePath | ||
} else PathManager.getHomePath() + "/contrib/makefile/testData" | ||
} |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any way to make this fragment right-aligned? I tried different values for
padding
of this and filename fragments together withalignment = RIGHT
- no effect.