Skip to content

Commit

Permalink
"Compile" also uses aspects and output groups so we need repository o…
Browse files Browse the repository at this point in the history
…verrides for now (#7135)
  • Loading branch information
dkashyn-sfdc authored Dec 9, 2024
1 parent a145037 commit d5f47f3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion base/src/META-INF/blaze-base.xml
Original file line number Diff line number Diff line change
Expand Up @@ -630,7 +630,7 @@
<SyncPlugin implementation="com.google.idea.blaze.base.lang.buildfile.sync.BuildLangSyncPlugin"/>
<SyncPlugin implementation="com.google.idea.blaze.base.sync.libraries.ExternalLibraryManager$SyncPlugin"/>
<BuildFlagsProvider implementation="com.google.idea.blaze.base.command.BuildFlagsProviderImpl"/>
<BuildFlagsProvider implementation="com.google.idea.blaze.base.sync.aspects.AspactBuildFlagsProvider"/>
<BuildFlagsProvider implementation="com.google.idea.blaze.base.sync.aspects.AspectBuildFlagsProvider"/>
<BuildFlagsProvider implementation="com.google.idea.blaze.base.run.coverage.CoverageBuildFlagsProvider"/>
<VcsHandler implementation="com.google.idea.blaze.base.vcs.git.GitBlazeVcsHandlerProvider"/>
<VcsHandler implementation="com.google.idea.blaze.base.vcs.FallbackBlazeVcsHandlerProvider" order="last" id="fallback"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import java.util.List;
import java.util.Optional;

public class AspactBuildFlagsProvider implements BuildFlagsProvider {
public class AspectBuildFlagsProvider implements BuildFlagsProvider {

@Override
public void addBuildFlags(
Expand All @@ -20,7 +20,9 @@ public void addBuildFlags(
BlazeCommandName command,
BlazeInvocationContext invocationContext,
List<String> flags) {
// aspects are only required during sync
Arrays.stream(AspectRepositoryProvider.getOverrideFlags(project)).filter(Optional::isPresent)
.map(Optional::get)
.forEach(flags::add);
}

@Override
Expand Down

0 comments on commit d5f47f3

Please sign in to comment.