diff --git a/README.md b/README.md index 769b0cd..7ab1146 100644 --- a/README.md +++ b/README.md @@ -11,11 +11,11 @@ ## Установка через fyne: 1. go install fyne.io/fyne/v2/cmd/fyne@latest -2. fyne get git.kor-elf.net/kor-elf/gui-for-ffmpeg/src +2. fyne get git.kor-elf.net/kor-elf/gui-for-ffmpeg ## Скомпилировать через исходники: 1. git clone https://git.kor-elf.net/kor-elf/gui-for-ffmpeg.git -2. Переходим в папку проекта и там переходим в папку src: **cd gui-for-ffmpeg/src** +2. Переходим в папку проекта и там переходим в папку src: **cd gui-for-ffmpeg** 3. Ознакамливаемся, что нужно ещё установить для Вашей ОС для простого запуска (через go run) тут: https://docs.fyne.io/started/ 4. *(не обязательный шаг)* Просто запустить можно так: **go run main.go** 5. go install github.com/fyne-io/fyne-cross@latest @@ -35,9 +35,8 @@ ## Работа с переводами: 1. go install -v github.com/nicksnyder/go-i18n/v2/goi18n@latest -2. Переходим в папке проекта в папку src: **cd ./src** -3. goi18n merge -sourceLanguage ru -outdir languages languages/active.\*.toml languages/translate.\*.toml -4. В файлах **languages/translate.\*.toml** переводим текст на нужный язык -5. goi18n merge -sourceLanguage ru -outdir languages languages/active.\*.toml languages/translate.\*.toml +2. goi18n merge -sourceLanguage ru -outdir languages languages/active.\*.toml languages/translate.\*.toml +3. В файлах **languages/translate.\*.toml** переводим текст на нужный язык +4. goi18n merge -sourceLanguage ru -outdir languages languages/active.\*.toml languages/translate.\*.toml Более подробно можно почитать тут: https://github.com/nicksnyder/go-i18n \ No newline at end of file diff --git a/src/convertor/repository.go b/convertor/repository.go similarity index 94% rename from src/convertor/repository.go rename to convertor/repository.go index 3f26bf5..e31f64a 100644 --- a/src/convertor/repository.go +++ b/convertor/repository.go @@ -1,7 +1,7 @@ package convertor import ( - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/setting" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/setting" ) type RepositoryContract interface { diff --git a/src/convertor/service.go b/convertor/service.go similarity index 98% rename from src/convertor/service.go rename to convertor/service.go index bdeb256..9b89f1f 100644 --- a/src/convertor/service.go +++ b/convertor/service.go @@ -2,7 +2,7 @@ package convertor import ( "errors" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/helper" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/helper" "io" "os/exec" "regexp" diff --git a/src/convertor/view.go b/convertor/view.go similarity index 98% rename from src/convertor/view.go rename to convertor/view.go index 7a18160..2ac293d 100644 --- a/src/convertor/view.go +++ b/convertor/view.go @@ -8,8 +8,8 @@ import ( "fyne.io/fyne/v2/dialog" "fyne.io/fyne/v2/storage" "fyne.io/fyne/v2/widget" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/helper" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/localizer" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/helper" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/localizer" "github.com/nicksnyder/go-i18n/v2/i18n" "image/color" "path/filepath" diff --git a/src/convertor/view_setting.go b/convertor/view_setting.go similarity index 98% rename from src/convertor/view_setting.go rename to convertor/view_setting.go index c09acba..703259f 100644 --- a/src/convertor/view_setting.go +++ b/convertor/view_setting.go @@ -7,7 +7,7 @@ import ( "fyne.io/fyne/v2/dialog" "fyne.io/fyne/v2/storage" "fyne.io/fyne/v2/widget" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/helper" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/helper" "github.com/nicksnyder/go-i18n/v2/i18n" "image/color" "net/url" diff --git a/src/convertor/view_setting_button_download_ffmpeg_anyos.go b/convertor/view_setting_button_download_ffmpeg_anyos.go similarity index 100% rename from src/convertor/view_setting_button_download_ffmpeg_anyos.go rename to convertor/view_setting_button_download_ffmpeg_anyos.go diff --git a/src/convertor/view_setting_button_download_ffmpeg_windows.go b/convertor/view_setting_button_download_ffmpeg_windows.go similarity index 100% rename from src/convertor/view_setting_button_download_ffmpeg_windows.go rename to convertor/view_setting_button_download_ffmpeg_windows.go diff --git a/src/data/.gitignore b/data/.gitignore similarity index 100% rename from src/data/.gitignore rename to data/.gitignore diff --git a/src/error/view.go b/error/view.go similarity index 96% rename from src/error/view.go rename to error/view.go index 61bd0f4..f34d72b 100644 --- a/src/error/view.go +++ b/error/view.go @@ -4,7 +4,7 @@ import ( "fyne.io/fyne/v2" "fyne.io/fyne/v2/container" "fyne.io/fyne/v2/widget" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/localizer" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/localizer" "github.com/nicksnyder/go-i18n/v2/i18n" ) diff --git a/src/go.mod b/go.mod similarity index 97% rename from src/go.mod rename to go.mod index 66edcf3..89427e3 100644 --- a/src/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module git.kor-elf.net/kor-elf/gui-for-ffmpeg/src +module git.kor-elf.net/kor-elf/gui-for-ffmpeg go 1.21 diff --git a/src/go.sum b/go.sum similarity index 100% rename from src/go.sum rename to go.sum diff --git a/src/handler/convertor.go b/handler/convertor.go similarity index 97% rename from src/handler/convertor.go rename to handler/convertor.go index e878665..5a2cff1 100644 --- a/src/handler/convertor.go +++ b/handler/convertor.go @@ -4,9 +4,9 @@ import ( "bufio" "errors" "fyne.io/fyne/v2/widget" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/convertor" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/helper" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/localizer" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/convertor" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/helper" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/localizer" "github.com/nicksnyder/go-i18n/v2/i18n" "io" "regexp" diff --git a/src/handler/convertor_anyos.go b/handler/convertor_anyos.go similarity index 87% rename from src/handler/convertor_anyos.go rename to handler/convertor_anyos.go index 16b85a0..4db2fd4 100644 --- a/src/handler/convertor_anyos.go +++ b/handler/convertor_anyos.go @@ -6,7 +6,7 @@ package handler import ( "fyne.io/fyne/v2/canvas" "fyne.io/fyne/v2/widget" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/convertor" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/convertor" ) func getPathsToFF() []convertor.FFPathUtilities { diff --git a/src/handler/convertor_windows.go b/handler/convertor_windows.go similarity index 100% rename from src/handler/convertor_windows.go rename to handler/convertor_windows.go diff --git a/src/handler/main.go b/handler/main.go similarity index 94% rename from src/handler/main.go rename to handler/main.go index 7253b05..48b99a4 100644 --- a/src/handler/main.go +++ b/handler/main.go @@ -1,7 +1,7 @@ package handler import ( - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/localizer" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/localizer" ) type MainHandler struct { diff --git a/src/handler/menu.go b/handler/menu.go similarity index 97% rename from src/handler/menu.go rename to handler/menu.go index bf7e332..eabbef2 100644 --- a/src/handler/menu.go +++ b/handler/menu.go @@ -2,8 +2,8 @@ package handler import ( "fyne.io/fyne/v2" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/localizer" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/menu" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/localizer" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/menu" "github.com/nicksnyder/go-i18n/v2/i18n" ) diff --git a/src/helper/helper.go b/helper/helper.go similarity index 100% rename from src/helper/helper.go rename to helper/helper.go diff --git a/src/helper/path_separator.go b/helper/path_separator.go similarity index 100% rename from src/helper/path_separator.go rename to helper/path_separator.go diff --git a/src/helper/path_separator_window.go b/helper/path_separator_window.go similarity index 100% rename from src/helper/path_separator_window.go rename to helper/path_separator_window.go diff --git a/src/helper/prepare_background_command.go b/helper/prepare_background_command.go similarity index 100% rename from src/helper/prepare_background_command.go rename to helper/prepare_background_command.go diff --git a/src/helper/prepare_background_command_windows.go b/helper/prepare_background_command_windows.go similarity index 100% rename from src/helper/prepare_background_command_windows.go rename to helper/prepare_background_command_windows.go diff --git a/src/icon.png b/icon.png similarity index 100% rename from src/icon.png rename to icon.png diff --git a/src/languages/active.en.toml b/languages/active.en.toml similarity index 100% rename from src/languages/active.en.toml rename to languages/active.en.toml diff --git a/src/languages/active.kk.toml b/languages/active.kk.toml similarity index 100% rename from src/languages/active.kk.toml rename to languages/active.kk.toml diff --git a/src/languages/active.ru.toml b/languages/active.ru.toml similarity index 100% rename from src/languages/active.ru.toml rename to languages/active.ru.toml diff --git a/src/languages/translate.en.toml b/languages/translate.en.toml similarity index 100% rename from src/languages/translate.en.toml rename to languages/translate.en.toml diff --git a/src/languages/translate.kk.toml b/languages/translate.kk.toml similarity index 100% rename from src/languages/translate.kk.toml rename to languages/translate.kk.toml diff --git a/src/localizer/repository.go b/localizer/repository.go similarity index 91% rename from src/localizer/repository.go rename to localizer/repository.go index 03c7fa3..46e36f2 100644 --- a/src/localizer/repository.go +++ b/localizer/repository.go @@ -1,7 +1,7 @@ package localizer import ( - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/setting" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/setting" ) type RepositoryContract interface { diff --git a/src/localizer/service.go b/localizer/service.go similarity index 100% rename from src/localizer/service.go rename to localizer/service.go diff --git a/src/localizer/view.go b/localizer/view.go similarity index 100% rename from src/localizer/view.go rename to localizer/view.go diff --git a/src/main.go b/main.go similarity index 89% rename from src/main.go rename to main.go index f992a23..8b1dbc1 100644 --- a/src/main.go +++ b/main.go @@ -6,13 +6,13 @@ import ( "fyne.io/fyne/v2/app" "fyne.io/fyne/v2/container" "fyne.io/fyne/v2/widget" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/convertor" - error2 "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/error" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/handler" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/localizer" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/menu" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/migration" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/setting" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/convertor" + error2 "git.kor-elf.net/kor-elf/gui-for-ffmpeg/error" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/handler" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/localizer" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/menu" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/migration" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/setting" _ "github.com/mattn/go-sqlite3" "golang.org/x/text/language" "gorm.io/driver/sqlite" diff --git a/src/menu/view.go b/menu/view.go similarity index 99% rename from src/menu/view.go rename to menu/view.go index 377dd6e..0dc0896 100644 --- a/src/menu/view.go +++ b/menu/view.go @@ -5,7 +5,7 @@ import ( "fyne.io/fyne/v2/canvas" "fyne.io/fyne/v2/container" "fyne.io/fyne/v2/widget" - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/localizer" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/localizer" "github.com/nicksnyder/go-i18n/v2/i18n" "golang.org/x/image/colornames" "net/url" diff --git a/src/migration/migration.go b/migration/migration.go similarity index 75% rename from src/migration/migration.go rename to migration/migration.go index 91787ff..932b98a 100644 --- a/src/migration/migration.go +++ b/migration/migration.go @@ -1,7 +1,7 @@ package migration import ( - "git.kor-elf.net/kor-elf/gui-for-ffmpeg/src/setting" + "git.kor-elf.net/kor-elf/gui-for-ffmpeg/setting" "gorm.io/gorm" ) diff --git a/src/setting/entity.go b/setting/entity.go similarity index 100% rename from src/setting/entity.go rename to setting/entity.go diff --git a/src/setting/repository.go b/setting/repository.go similarity index 100% rename from src/setting/repository.go rename to setting/repository.go