From 4705e753b55298b75f88c5866e1d7765d0852528 Mon Sep 17 00:00:00 2001 From: "Maria.Tigina" Date: Tue, 16 Jan 2024 13:40:24 +0100 Subject: [PATCH] Add introduction section --- README.md | 4 +-- course-info.yaml | 3 +- introductionSection/section-info.yaml | 3 ++ introductionSection/section-remote-info.yaml | 1 + .../plugin/course/dev/welcome/HelloHelena.kt | 10 +++++++ .../helloHelenaTask/task-info.yaml | 7 +++++ .../helloHelenaTask}/task-remote-info.yaml | 0 .../welcomeLesson/helloHelenaTask/task.md | 10 +++++++ .../plugin/course/dev/welcome/Tests.kt | 28 +++++++++++++++++++ .../plugin/course/dev/welcome/HelloJonsi.kt | 10 +++++++ .../helpJonsiTask/task-info.yaml | 12 ++++++++ .../helpJonsiTask/task-remote-info.yaml | 1 + .../welcomeLesson/helpJonsiTask/task.md | 5 ++++ .../welcomeLesson/lesson-info.yaml | 4 +++ .../course/dev/access/ElementsCounter.kt | 0 .../task-info.yaml | 0 .../task-remote-info.yaml | 0 .../task.md | 0 .../academy/plugin/course/dev/access/Tests.kt | 0 .../course/dev/access/ElementsCounter.kt | 0 .../task-info.yaml | 0 .../task-remote-info.yaml | 0 .../accessingPsiElementsTheoryTask/task.md | 0 .../lesson-info.yaml | 0 .../lesson-remote-info.yaml | 0 .../course/dev/access/AnnotationBuilder.kt | 0 .../task-info.yaml | 0 .../task-remote-info.yaml | 0 .../addingAnnotationsProgrammingTask/task.md | 0 .../academy/plugin/course/dev/access/Tests.kt | 0 .../academy/plugin/course/dev/access/Task.kt | 0 .../task-info.yaml | 0 .../task-remote-info.yaml | 0 .../addingPsiElementsTheoryTask/task.md | 0 .../addingPsiElementsLesson/lesson-info.yaml | 0 .../lesson-remote-info.yaml | 0 .../academy/plugin/course/dev/access/Task.kt | 0 .../task-info.yaml | 0 .../task-remote-info.yaml | 0 .../editingPsiElementsTheoryTask/task.md | 0 .../editingPsiElementsLesson/lesson-info.yaml | 0 .../lesson-remote-info.yaml | 0 .../course/dev/access/FunctionNameChanger.kt | 0 .../task-info.yaml | 0 .../task-remote-info.yaml | 0 .../renameFunctionProgrammingTask/task.md | 0 .../academy/plugin/course/dev/access/Tests.kt | 0 .../course/dev/access/PsiElementsSorter.kt | 0 .../sortMethodsProgrammingTask/task-info.yaml | 0 .../task-remote-info.yaml | 0 .../sortMethodsProgrammingTask/task.md | 0 .../academy/plugin/course/dev/access/Tests.kt | 0 .../academy/plugin/course/dev/intro/Person.kt | 0 .../IntroToPsiLesson/task-info.yaml | 0 .../IntroToPsiLesson/task-remote-info.yaml | 1 + .../IntroToPsiLesson/task.md | 22 +++++++-------- .../academy/plugin/course/dev/intro/Person.kt | 0 .../TryPsiViewerLesson/task-info.yaml | 2 +- .../TryPsiViewerLesson/task-remote-info.yaml | 0 .../TryPsiViewerLesson/task.md | 0 .../introductionToPsiLesson/lesson-info.yaml | 0 .../lesson-remote-info.yaml | 0 .../section-info.yaml | 0 .../section-remote-info.yaml | 0 64 files changed, 108 insertions(+), 15 deletions(-) create mode 100644 introductionSection/section-info.yaml create mode 100644 introductionSection/section-remote-info.yaml create mode 100644 introductionSection/welcomeLesson/helloHelenaTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloHelena.kt create mode 100644 introductionSection/welcomeLesson/helloHelenaTask/task-info.yaml rename {courseSection/introductionToPsiLesson/IntroToPsiLesson => introductionSection/welcomeLesson/helloHelenaTask}/task-remote-info.yaml (100%) create mode 100644 introductionSection/welcomeLesson/helloHelenaTask/task.md create mode 100644 introductionSection/welcomeLesson/helloHelenaTask/test/org/jetbrains/academy/plugin/course/dev/welcome/Tests.kt create mode 100644 introductionSection/welcomeLesson/helpJonsiTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloJonsi.kt create mode 100644 introductionSection/welcomeLesson/helpJonsiTask/task-info.yaml create mode 100644 introductionSection/welcomeLesson/helpJonsiTask/task-remote-info.yaml create mode 100644 introductionSection/welcomeLesson/helpJonsiTask/task.md create mode 100644 introductionSection/welcomeLesson/lesson-info.yaml rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-info.yaml (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-remote-info.yaml (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task.md (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-info.yaml (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-remote-info.yaml (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task.md (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/lesson-info.yaml (100%) rename {courseSection => psiSection}/accessingPsiElementsLesson/lesson-remote-info.yaml (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingAnnotationsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/AnnotationBuilder.kt (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-info.yaml (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-remote-info.yaml (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task.md (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingAnnotationsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-info.yaml (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-remote-info.yaml (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/addingPsiElementsTheoryTask/task.md (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/lesson-info.yaml (100%) rename {courseSection => psiSection}/addingPsiElementsLesson/lesson-remote-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/editingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-remote-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/editingPsiElementsTheoryTask/task.md (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/lesson-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/lesson-remote-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/renameFunctionProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/FunctionNameChanger.kt (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/renameFunctionProgrammingTask/task-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/renameFunctionProgrammingTask/task-remote-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/renameFunctionProgrammingTask/task.md (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/renameFunctionProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/sortMethodsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/PsiElementsSorter.kt (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/sortMethodsProgrammingTask/task-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/sortMethodsProgrammingTask/task-remote-info.yaml (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/sortMethodsProgrammingTask/task.md (100%) rename {courseSection => psiSection}/editingPsiElementsLesson/sortMethodsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt (100%) rename {courseSection => psiSection}/introductionToPsiLesson/IntroToPsiLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt (100%) rename {courseSection => psiSection}/introductionToPsiLesson/IntroToPsiLesson/task-info.yaml (100%) create mode 100644 psiSection/introductionToPsiLesson/IntroToPsiLesson/task-remote-info.yaml rename {courseSection => psiSection}/introductionToPsiLesson/IntroToPsiLesson/task.md (62%) rename {courseSection => psiSection}/introductionToPsiLesson/TryPsiViewerLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt (100%) rename {courseSection => psiSection}/introductionToPsiLesson/TryPsiViewerLesson/task-info.yaml (94%) rename {courseSection => psiSection}/introductionToPsiLesson/TryPsiViewerLesson/task-remote-info.yaml (100%) rename {courseSection => psiSection}/introductionToPsiLesson/TryPsiViewerLesson/task.md (100%) rename {courseSection => psiSection}/introductionToPsiLesson/lesson-info.yaml (100%) rename {courseSection => psiSection}/introductionToPsiLesson/lesson-remote-info.yaml (100%) rename {courseSection => psiSection}/section-info.yaml (100%) rename {courseSection => psiSection}/section-remote-info.yaml (100%) diff --git a/README.md b/README.md index 5d61292..52f6fde 100644 --- a/README.md +++ b/README.md @@ -259,8 +259,8 @@ In the `.github/workflows` directory, you can find definitions for the following [file:gradle.properties]: ./gradle.properties [file:course-info.yaml]: ./course-info.yaml [file:courseignore]: .courseignore -[file:course.lesson.tests]: courseSection/psi/programmingTask/test/Tests.kt -[file:course.framework.lesson.tests]: ./courseSection/courseFrameworkLesson/programmingTask/test/Tests.kt +[file:course.lesson.tests]: psiSection/psi/programmingTask/test/Tests.kt +[file:course.framework.lesson.tests]: psiSection/courseFrameworkLesson/programmingTask/test/Tests.kt [gradle]: https://gradle.org diff --git a/course-info.yaml b/course-info.yaml index 2db93fb..ff8591f 100644 --- a/course-info.yaml +++ b/course-info.yaml @@ -4,6 +4,7 @@ language: English summary: TODO programming_language: Kotlin content: - - courseSection + - introductionSection + - psiSection environment_settings: jvm_language_level: JDK_17 diff --git a/introductionSection/section-info.yaml b/introductionSection/section-info.yaml new file mode 100644 index 0000000..60a2fc3 --- /dev/null +++ b/introductionSection/section-info.yaml @@ -0,0 +1,3 @@ +custom_name: Introduction +content: + - welcomeLesson diff --git a/introductionSection/section-remote-info.yaml b/introductionSection/section-remote-info.yaml new file mode 100644 index 0000000..07c18cf --- /dev/null +++ b/introductionSection/section-remote-info.yaml @@ -0,0 +1 @@ +id: 459294228 diff --git a/introductionSection/welcomeLesson/helloHelenaTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloHelena.kt b/introductionSection/welcomeLesson/helloHelenaTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloHelena.kt new file mode 100644 index 0000000..deaf4da --- /dev/null +++ b/introductionSection/welcomeLesson/helloHelenaTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloHelena.kt @@ -0,0 +1,10 @@ +package org.jetbrains.academy.plugin.course.dev.welcome + +fun sayHelloHelena(howManyTimes: Int): String { + TODO() +} + +fun main() { + val howManyTimes = readln().toInt() + print(sayHelloHelena(howManyTimes)) +} diff --git a/introductionSection/welcomeLesson/helloHelenaTask/task-info.yaml b/introductionSection/welcomeLesson/helloHelenaTask/task-info.yaml new file mode 100644 index 0000000..df4c38a --- /dev/null +++ b/introductionSection/welcomeLesson/helloHelenaTask/task-info.yaml @@ -0,0 +1,7 @@ +type: edu +custom_name: Hello Helena! +files: + - name: src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloHelena.kt + visible: true + - name: test/org/jetbrains/academy/plugin/course/dev/welcome/Tests.kt + visible: false diff --git a/courseSection/introductionToPsiLesson/IntroToPsiLesson/task-remote-info.yaml b/introductionSection/welcomeLesson/helloHelenaTask/task-remote-info.yaml similarity index 100% rename from courseSection/introductionToPsiLesson/IntroToPsiLesson/task-remote-info.yaml rename to introductionSection/welcomeLesson/helloHelenaTask/task-remote-info.yaml diff --git a/introductionSection/welcomeLesson/helloHelenaTask/task.md b/introductionSection/welcomeLesson/helloHelenaTask/task.md new file mode 100644 index 0000000..0d7b61c --- /dev/null +++ b/introductionSection/welcomeLesson/helloHelenaTask/task.md @@ -0,0 +1,10 @@ +Hi! My name is Helena. I’m working in the Plugin Development Team. We have just hired a new young developer, Jonsi, so I’ve prepared lots of amazing projects for him to do. + +But wait, he has never worked with IntelliJ Platform before?! So well, I’ll try to teach him all important things during one week of his probation. + +Say hello to Helena! Add implementation to method `helloHelena` method which should return “Hello, Helena!” given number of times, separated by new line. + +
+ +Use `System.lineSeparator()` to get platform specific new line symbol +
diff --git a/introductionSection/welcomeLesson/helloHelenaTask/test/org/jetbrains/academy/plugin/course/dev/welcome/Tests.kt b/introductionSection/welcomeLesson/helloHelenaTask/test/org/jetbrains/academy/plugin/course/dev/welcome/Tests.kt new file mode 100644 index 0000000..ed536f0 --- /dev/null +++ b/introductionSection/welcomeLesson/helloHelenaTask/test/org/jetbrains/academy/plugin/course/dev/welcome/Tests.kt @@ -0,0 +1,28 @@ +package org.jetbrains.academy.plugin.course.dev.welcome + + +import org.junit.Assert.assertEquals +import org.junit.Test +import org.junit.runner.RunWith +import org.junit.runners.Parameterized + +@RunWith(Parameterized::class) +class Test(private val howManyTimes: Int) { + + private fun expectedSayHelloHelena(howManyTimes: Int): String { + return List(howManyTimes) { "Hello, Helena!" }.joinToString(System.lineSeparator()) + } + + @Test + fun test() { + assertEquals(expectedSayHelloHelena(howManyTimes), sayHelloHelena(howManyTimes)) + } + + companion object { + @JvmStatic + @Parameterized.Parameters + fun data(): List { + return listOf(1, 5, 10, 100) + } + } +} \ No newline at end of file diff --git a/introductionSection/welcomeLesson/helpJonsiTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloJonsi.kt b/introductionSection/welcomeLesson/helpJonsiTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloJonsi.kt new file mode 100644 index 0000000..c4cbefa --- /dev/null +++ b/introductionSection/welcomeLesson/helpJonsiTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloJonsi.kt @@ -0,0 +1,10 @@ +package org.jetbrains.academy.plugin.course.dev.welcome + +fun sayHelloJonsi(howManyTimes: Int): String { + return List(howManyTimes) { "Hello, Jonsi!" }.joinToString(System.lineSeparator()) +} + +fun main() { + val howManyTimes = readln().toInt() + print(sayHelloJonsi(howManyTimes)) +} diff --git a/introductionSection/welcomeLesson/helpJonsiTask/task-info.yaml b/introductionSection/welcomeLesson/helpJonsiTask/task-info.yaml new file mode 100644 index 0000000..d334d13 --- /dev/null +++ b/introductionSection/welcomeLesson/helpJonsiTask/task-info.yaml @@ -0,0 +1,12 @@ +type: choice +custom_name: Ready to Help Jonsi? +is_multiple_choice: false +options: + - text: "yes" + is_correct: true + - text: "no" + is_correct: false +files: + - name: src/main/kotlin/org/jetbrains/academy/plugin/course/dev/welcome/HelloJonsi.kt + visible: true +local_check: true diff --git a/introductionSection/welcomeLesson/helpJonsiTask/task-remote-info.yaml b/introductionSection/welcomeLesson/helpJonsiTask/task-remote-info.yaml new file mode 100644 index 0000000..b785cb2 --- /dev/null +++ b/introductionSection/welcomeLesson/helpJonsiTask/task-remote-info.yaml @@ -0,0 +1 @@ +id: 853483765 diff --git a/introductionSection/welcomeLesson/helpJonsiTask/task.md b/introductionSection/welcomeLesson/helpJonsiTask/task.md new file mode 100644 index 0000000..6ef0353 --- /dev/null +++ b/introductionSection/welcomeLesson/helpJonsiTask/task.md @@ -0,0 +1,5 @@ +Hi! My name is Jonsi! It’s my first day at JetBrains, and I’m ready to start! But I’m really nervous of my probation week as I have no idea, how IDE works behind and what is more, how to write plugins for it. + +So I really need someone's help!!! + +Maybe you can help me? diff --git a/introductionSection/welcomeLesson/lesson-info.yaml b/introductionSection/welcomeLesson/lesson-info.yaml new file mode 100644 index 0000000..b143729 --- /dev/null +++ b/introductionSection/welcomeLesson/lesson-info.yaml @@ -0,0 +1,4 @@ +custom_name: Welcome and good luck! +content: + - helloHelenaTask + - helpJonsiTask diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt b/psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-info.yaml b/psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-info.yaml similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-info.yaml rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-info.yaml diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-remote-info.yaml b/psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-remote-info.yaml similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-remote-info.yaml rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task-remote-info.yaml diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task.md b/psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task.md similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task.md rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/task.md diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt b/psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsClassProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt b/psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/ElementsCounter.kt diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-info.yaml b/psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-info.yaml similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-info.yaml rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-info.yaml diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-remote-info.yaml b/psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-remote-info.yaml similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-remote-info.yaml rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task-remote-info.yaml diff --git a/courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task.md b/psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task.md similarity index 100% rename from courseSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task.md rename to psiSection/accessingPsiElementsLesson/accessingPsiElementsTheoryTask/task.md diff --git a/courseSection/accessingPsiElementsLesson/lesson-info.yaml b/psiSection/accessingPsiElementsLesson/lesson-info.yaml similarity index 100% rename from courseSection/accessingPsiElementsLesson/lesson-info.yaml rename to psiSection/accessingPsiElementsLesson/lesson-info.yaml diff --git a/courseSection/accessingPsiElementsLesson/lesson-remote-info.yaml b/psiSection/accessingPsiElementsLesson/lesson-remote-info.yaml similarity index 100% rename from courseSection/accessingPsiElementsLesson/lesson-remote-info.yaml rename to psiSection/accessingPsiElementsLesson/lesson-remote-info.yaml diff --git a/courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/AnnotationBuilder.kt b/psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/AnnotationBuilder.kt similarity index 100% rename from courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/AnnotationBuilder.kt rename to psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/AnnotationBuilder.kt diff --git a/courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-info.yaml b/psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-info.yaml similarity index 100% rename from courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-info.yaml rename to psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-info.yaml diff --git a/courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-remote-info.yaml b/psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-remote-info.yaml similarity index 100% rename from courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-remote-info.yaml rename to psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task-remote-info.yaml diff --git a/courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task.md b/psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task.md similarity index 100% rename from courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task.md rename to psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/task.md diff --git a/courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt b/psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt similarity index 100% rename from courseSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt rename to psiSection/addingPsiElementsLesson/addingAnnotationsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt diff --git a/courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt b/psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt similarity index 100% rename from courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt rename to psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt diff --git a/courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-info.yaml b/psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-info.yaml similarity index 100% rename from courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-info.yaml rename to psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-info.yaml diff --git a/courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-remote-info.yaml b/psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-remote-info.yaml similarity index 100% rename from courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-remote-info.yaml rename to psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task-remote-info.yaml diff --git a/courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task.md b/psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task.md similarity index 100% rename from courseSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task.md rename to psiSection/addingPsiElementsLesson/addingPsiElementsTheoryTask/task.md diff --git a/courseSection/addingPsiElementsLesson/lesson-info.yaml b/psiSection/addingPsiElementsLesson/lesson-info.yaml similarity index 100% rename from courseSection/addingPsiElementsLesson/lesson-info.yaml rename to psiSection/addingPsiElementsLesson/lesson-info.yaml diff --git a/courseSection/addingPsiElementsLesson/lesson-remote-info.yaml b/psiSection/addingPsiElementsLesson/lesson-remote-info.yaml similarity index 100% rename from courseSection/addingPsiElementsLesson/lesson-remote-info.yaml rename to psiSection/addingPsiElementsLesson/lesson-remote-info.yaml diff --git a/courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt b/psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt similarity index 100% rename from courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt rename to psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/Task.kt diff --git a/courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-info.yaml b/psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-info.yaml rename to psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-info.yaml diff --git a/courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-remote-info.yaml b/psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-remote-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-remote-info.yaml rename to psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task-remote-info.yaml diff --git a/courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task.md b/psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task.md similarity index 100% rename from courseSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task.md rename to psiSection/editingPsiElementsLesson/editingPsiElementsTheoryTask/task.md diff --git a/courseSection/editingPsiElementsLesson/lesson-info.yaml b/psiSection/editingPsiElementsLesson/lesson-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/lesson-info.yaml rename to psiSection/editingPsiElementsLesson/lesson-info.yaml diff --git a/courseSection/editingPsiElementsLesson/lesson-remote-info.yaml b/psiSection/editingPsiElementsLesson/lesson-remote-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/lesson-remote-info.yaml rename to psiSection/editingPsiElementsLesson/lesson-remote-info.yaml diff --git a/courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/FunctionNameChanger.kt b/psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/FunctionNameChanger.kt similarity index 100% rename from courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/FunctionNameChanger.kt rename to psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/FunctionNameChanger.kt diff --git a/courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-info.yaml b/psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-info.yaml rename to psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-info.yaml diff --git a/courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-remote-info.yaml b/psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-remote-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-remote-info.yaml rename to psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task-remote-info.yaml diff --git a/courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task.md b/psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task.md similarity index 100% rename from courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task.md rename to psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/task.md diff --git a/courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt b/psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt similarity index 100% rename from courseSection/editingPsiElementsLesson/renameFunctionProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt rename to psiSection/editingPsiElementsLesson/renameFunctionProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt diff --git a/courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/PsiElementsSorter.kt b/psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/PsiElementsSorter.kt similarity index 100% rename from courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/PsiElementsSorter.kt rename to psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/access/PsiElementsSorter.kt diff --git a/courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-info.yaml b/psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-info.yaml rename to psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-info.yaml diff --git a/courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-remote-info.yaml b/psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-remote-info.yaml similarity index 100% rename from courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-remote-info.yaml rename to psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task-remote-info.yaml diff --git a/courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task.md b/psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task.md similarity index 100% rename from courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task.md rename to psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/task.md diff --git a/courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt b/psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt similarity index 100% rename from courseSection/editingPsiElementsLesson/sortMethodsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt rename to psiSection/editingPsiElementsLesson/sortMethodsProgrammingTask/test/org/jetbrains/academy/plugin/course/dev/access/Tests.kt diff --git a/courseSection/introductionToPsiLesson/IntroToPsiLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt b/psiSection/introductionToPsiLesson/IntroToPsiLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt similarity index 100% rename from courseSection/introductionToPsiLesson/IntroToPsiLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt rename to psiSection/introductionToPsiLesson/IntroToPsiLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt diff --git a/courseSection/introductionToPsiLesson/IntroToPsiLesson/task-info.yaml b/psiSection/introductionToPsiLesson/IntroToPsiLesson/task-info.yaml similarity index 100% rename from courseSection/introductionToPsiLesson/IntroToPsiLesson/task-info.yaml rename to psiSection/introductionToPsiLesson/IntroToPsiLesson/task-info.yaml diff --git a/psiSection/introductionToPsiLesson/IntroToPsiLesson/task-remote-info.yaml b/psiSection/introductionToPsiLesson/IntroToPsiLesson/task-remote-info.yaml new file mode 100644 index 0000000..b785cb2 --- /dev/null +++ b/psiSection/introductionToPsiLesson/IntroToPsiLesson/task-remote-info.yaml @@ -0,0 +1 @@ +id: 853483765 diff --git a/courseSection/introductionToPsiLesson/IntroToPsiLesson/task.md b/psiSection/introductionToPsiLesson/IntroToPsiLesson/task.md similarity index 62% rename from courseSection/introductionToPsiLesson/IntroToPsiLesson/task.md rename to psiSection/introductionToPsiLesson/IntroToPsiLesson/task.md index c6210a7..0840a0d 100644 --- a/courseSection/introductionToPsiLesson/IntroToPsiLesson/task.md +++ b/psiSection/introductionToPsiLesson/IntroToPsiLesson/task.md @@ -5,20 +5,20 @@ As you probably read there, PSI represents the entire structure of the code in a called a PSI tree. ### PSI Tree Structure -* The root is a [`PSI File`](https://plugins.jetbrains.com/docs/intellij/psi-files.html) element, representing an entire file. +* The root is a [`PSI File`](https://plugins.jetbrains.com/docs/intellij/psi-files.html) element, representing an entire file * Each node or [`PSI Element`](https://plugins.jetbrains.com/docs/intellij/psi-elements.html) in the tree represents a syntactic or structural part of the code, like expressions, -* statements, and declarations. +statements, and declarations ### Types of PSI Elements -* PsiFile: Represents an entire file. -* PsiClass: Represents a class in the code. -* PsiMethod: Represents a method. -* PsiVariable: Represents a variable. -* PsiExpression: Represents an expression, and so on. +* PsiFile: Represents an entire file +* PsiClass: Represents a class in the code +* PsiMethod: Represents a method +* PsiVariable: Represents a variable +* PsiExpression: Represents an expression, and so on -Each language (Java/Kotlin/Python) has their own implementations of [`PsiElement`](https://github.com/JetBrains/intellij-community/blob/master/platform/core-api/src/com/intellij/psi/PsiElement.java), +Each language (Java, Kotlin, Python, etc.) has their own implementations of [`PsiElement`](https://github.com/JetBrains/intellij-community/blob/master/platform/core-api/src/com/intellij/psi/PsiElement.java), so for example for file abstraction there are following options: -* [`com.intellij.psi.PsiFile`](https://github.com/JetBrains/intellij-community/blob/idea/232.10227.8/platform/core-api/src/com/intellij/psi/PsiFile.java): Represents an Java file. -* [`org.jetbrains.kotlin.psi.KtFile`](https://github.com/JetBrains/kotlin/blob/master/compiler/psi/src/org/jetbrains/kotlin/psi/KtFile.kt): Represents a Kotlin file. -* [`com.jetbrains.python.psi.PyFile`](https://github.com/JetBrains/intellij-community/blob/master/python/python-psi-api/src/com/jetbrains/python/psi/PyFile.java#L28): Represents a Python file. +* [`com.intellij.psi.PsiFile`](https://github.com/JetBrains/intellij-community/blob/idea/232.10227.8/platform/core-api/src/com/intellij/psi/PsiFile.java): Represents an Java file +* [`org.jetbrains.kotlin.psi.KtFile`](https://github.com/JetBrains/kotlin/blob/master/compiler/psi/src/org/jetbrains/kotlin/psi/KtFile.kt): Represents a Kotlin file +* [`com.jetbrains.python.psi.PyFile`](https://github.com/JetBrains/intellij-community/blob/master/python/python-psi-api/src/com/jetbrains/python/psi/PyFile.java#L28): Represents a Python file diff --git a/courseSection/introductionToPsiLesson/TryPsiViewerLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt b/psiSection/introductionToPsiLesson/TryPsiViewerLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt similarity index 100% rename from courseSection/introductionToPsiLesson/TryPsiViewerLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt rename to psiSection/introductionToPsiLesson/TryPsiViewerLesson/src/main/kotlin/org/jetbrains/academy/plugin/course/dev/intro/Person.kt diff --git a/courseSection/introductionToPsiLesson/TryPsiViewerLesson/task-info.yaml b/psiSection/introductionToPsiLesson/TryPsiViewerLesson/task-info.yaml similarity index 94% rename from courseSection/introductionToPsiLesson/TryPsiViewerLesson/task-info.yaml rename to psiSection/introductionToPsiLesson/TryPsiViewerLesson/task-info.yaml index 91891d4..b6629a3 100644 --- a/courseSection/introductionToPsiLesson/TryPsiViewerLesson/task-info.yaml +++ b/psiSection/introductionToPsiLesson/TryPsiViewerLesson/task-info.yaml @@ -1,5 +1,5 @@ type: choice -custom_name: Try PS Viewer +custom_name: Try PSI Viewer is_multiple_choice: true options: - text: org.jetbrains.kotlin.psi.KtClass diff --git a/courseSection/introductionToPsiLesson/TryPsiViewerLesson/task-remote-info.yaml b/psiSection/introductionToPsiLesson/TryPsiViewerLesson/task-remote-info.yaml similarity index 100% rename from courseSection/introductionToPsiLesson/TryPsiViewerLesson/task-remote-info.yaml rename to psiSection/introductionToPsiLesson/TryPsiViewerLesson/task-remote-info.yaml diff --git a/courseSection/introductionToPsiLesson/TryPsiViewerLesson/task.md b/psiSection/introductionToPsiLesson/TryPsiViewerLesson/task.md similarity index 100% rename from courseSection/introductionToPsiLesson/TryPsiViewerLesson/task.md rename to psiSection/introductionToPsiLesson/TryPsiViewerLesson/task.md diff --git a/courseSection/introductionToPsiLesson/lesson-info.yaml b/psiSection/introductionToPsiLesson/lesson-info.yaml similarity index 100% rename from courseSection/introductionToPsiLesson/lesson-info.yaml rename to psiSection/introductionToPsiLesson/lesson-info.yaml diff --git a/courseSection/introductionToPsiLesson/lesson-remote-info.yaml b/psiSection/introductionToPsiLesson/lesson-remote-info.yaml similarity index 100% rename from courseSection/introductionToPsiLesson/lesson-remote-info.yaml rename to psiSection/introductionToPsiLesson/lesson-remote-info.yaml diff --git a/courseSection/section-info.yaml b/psiSection/section-info.yaml similarity index 100% rename from courseSection/section-info.yaml rename to psiSection/section-info.yaml diff --git a/courseSection/section-remote-info.yaml b/psiSection/section-remote-info.yaml similarity index 100% rename from courseSection/section-remote-info.yaml rename to psiSection/section-remote-info.yaml