- http://stackoverflow.com/questions/804115 (
rebase
vsmerge
). - https://www.atlassian.com/git/tutorials/merging-vs-rebasing (
rebase
vsmerge
) - https://www.atlassian.com/git/tutorials/undoing-changes/ (
reset
vscheckout
vsrevert
) - http://stackoverflow.com/questions/2221658 (HEAD^ vs HEAD~) (See
git rev-parse
) - http://stackoverflow.com/questions/292357 (
pull
vsfetch
) - http://stackoverflow.com/questions/39651 (
stash
vsbranch
) - http://stackoverflow.com/questions/8358035 (
reset
vscheckout
vsrevert
) - http://stackoverflow.com/questions/5798930 (
git reset
vsgit rm --cached
)
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
## I just ran into this after initializing a Visual Studio project _before_ adding a .gitignore file (like an idiot). | |
## I felt real dumb commiting a bunch of files I didn't need to, so the commands below should do the trick. The first two commands | |
## came from the second answer on this post: http://stackoverflow.com/questions/7527982/applying-gitignore-to-committed-files | |
# See the unwanted files: | |
git ls-files -ci --exclude-standard | |
# Remove the unwanted files: | |
git ls-files -ci --exclude-standard -z | xargs -0 git rm --cached |
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
main(List<String> args) { | |
Button btn = new Button(); | |
btn.setCallback((a){ | |
print(a); | |
}); | |
for(int i=0;i<4;++i){ | |
btn.tap(); | |
} | |
} |
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
<idea-plugin> | |
<id>com.awesome.formatter</id> <!--Enter your package, it should be unique--> | |
<name>Awesome GQL Formatter</name> | |
<vendor email="tgunix@gmail.com" url="http://www.rahullohra.com">RahulLohra</vendor> | |
<description><![CDATA[ | |
Lorem ipsum Lorem ipsum Lorem ipsum Lorem ipsum.<br> | |
Lorem ipsum | |
]]></description> |
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
package com.rahul.gqlformat; | |
import com.intellij.openapi.project.Project; | |
import javax.swing.*; | |
public class GqlView { | |
private JTextArea textArea; | |
private JButton btnImport; | |
private JPanel panel; | |
private JTextField tfVariableName; |
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
package com.rahul.gqlformat | |
import com.intellij.openapi.project.Project | |
import com.intellij.openapi.wm.ToolWindow | |
import com.intellij.openapi.wm.ToolWindowFactory | |
import com.intellij.ui.content.ContentFactory | |
class MyToolWindow : ToolWindowFactory { | |
override fun createToolWindowContent(project: Project, toolWindow: ToolWindow) { |
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
</idea-plugin> | |
<extensions defaultExtensionNs="com.intellij"> | |
<toolWindow | |
id="Gql Format" anchor="right" factoryClass="com.rahul.gqlformat.MyToolWindow"> | |
</toolWindow> | |
</extensions> | |
</idea-plugin> |
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
class EditorLogic { | |
val nodeCreator = NodeCreator() | |
var expressionElement: PsiElement? = null | |
fun selectCurrentFile(variableName: String, project: Project, textArea: JTextArea) { | |
reset() | |
val fileEditorManager = FileEditorManager.getInstance(project) | |
val virtualFile = fileEditorManager.openFiles |
OlderNewer