-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of github.com:badsyntax/vscode-entity-framework
- Loading branch information
Showing
22 changed files
with
292 additions
and
177 deletions.
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import * as vscode from 'vscode'; | ||
import { CommandProvider } from '../commands/CommandProvider'; | ||
import { RefreshTreeCommand } from '../commands/RefreshTreeCommand'; | ||
import type { TerminalProvider } from '../terminal/TerminalProvider'; | ||
import type { MigrationTreeItem } from '../treeView/MigrationTreeItem'; | ||
import type { IAction } from './IAction'; | ||
import { RemoveMigrationAction } from './RemoveMigrationAction'; | ||
|
||
export class RemoveMigrationsAction implements IAction { | ||
constructor( | ||
private readonly terminalProvider: TerminalProvider, | ||
private readonly workspaceRoot: string, | ||
private readonly dbContext: string, | ||
private readonly project: string, | ||
private readonly migrationsToRemove: MigrationTreeItem[], | ||
) {} | ||
|
||
public async run() { | ||
for (let i = 0; i < this.migrationsToRemove.length; i++) { | ||
await new RemoveMigrationAction( | ||
this.terminalProvider, | ||
this.workspaceRoot, | ||
this.dbContext, | ||
this.project, | ||
false, | ||
).run(); | ||
} | ||
if (this.migrationsToRemove.length > 0) { | ||
await vscode.commands.executeCommand( | ||
CommandProvider.getCommandName(RefreshTreeCommand.commandName), | ||
false, | ||
); | ||
} | ||
} | ||
} |
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
Oops, something went wrong.