# 批量改名工具 **Repository Path**: colatea/colatea_rename ## Basic Information - **Project Name**: 批量改名工具 - **Description**: 批量改名工具(flutter desktop) - **Primary Language**: Dart - **License**: Apache-2.0 - **Default Branch**: dev - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 5 - **Forks**: 0 - **Created**: 2021-06-08 - **Last Updated**: 2021-09-13 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 批量修改名工具 for linux win ## 技术依赖 基于Flutter 2.0 get状态管理,走了一些坑,分享给大家 ```yaml dependencies: flutter: sdk: flutter # The following adds the Cupertino Icons font to your application. # Use with the CupertinoIcons class for iOS style icons. cupertino_icons: ^1.0.2 get: ^4.1.4 filesystem_picker: ^2.0.0-nullsafety.0 filepicker_windows: ^2.0.0 stack_trace: ^1.10.0 path_provider: ^2.0.2 json_table: ^2.0.1 file: ^6.1.1 url_launcher: ^6.0.6 window_size: git: url: git://github.com/google/flutter-desktop-embedding.git path: plugins/window_size ``` ## win linux 版本 运行截图如下 ## 安装 #### 1. windows是绿色版本,直接解压就可以 [Colatea批量改名工具v0.10-win.7z](https://gitee.com/colatea/colatea_rename/attach_files/734284/download/Colatea%E6%89%B9%E9%87%8F%E6%94%B9%E5%90%8D%E5%B7%A5%E5%85%B7v0.10-win.7z) #### 2 . linux版本 ```bash # 包内容 ls colatea_rename/ colatea_rename/install.sh colatea_rename/uninstall.sh colatea_rename/colatea-rename.png colatea_rename/colatea_rename-0.1.0-x86_64.AppImage # 解压后直接运行colatea_rename-0.1.0-x86_64.AppImage就行,如果没有权限 chmod a+x colatea_rename-0.1.0-x86_64.AppImage # 想要桌面快捷方式,会产生desktop文件 sh install.sh # 图标不喜欢可以换png文件 ``` [colatea_rename_0.1.0_appimage.tar.gz](https://gitee.com/colatea/colatea_rename/attach_files/734853/download/colatea_rename_0.1.0_appimage.tar.gz) ## 编译 ### windows编译 ```bash 下载源码,官方手册安装编译环境 https://flutter.cn/desktop # 注意windows我编译的时候flutter切换成了beta ``` ### linux编译 ```bash 我的开发环境是 manjaro $ neofetch ██████████████████ ████████ colatea@colatea-manjaro ██████████████████ ████████ ----------------------- ██████████████████ ████████ OS: Manjaro Linux x86_64 ██████████████████ ████████ Host: 10S4S02L00 ThinkCentre M920x-N000 ████████ ████████ Kernel: 5.10.41-1-MANJARO ████████ ████████ ████████ Uptime: 1 hour, 53 mins ████████ ████████ ████████ Packages: 1494 (pacman), 21 (snap) ████████ ████████ ████████ Shell: zsh 5.8 ████████ ████████ ████████ Resolution: 1920x1200 ████████ ████████ ████████ DE: GNOME ████████ ████████ ████████ WM: Mutter ████████ ████████ ████████ WM Theme: Matcha-dark-sea ████████ ████████ ████████ Theme: Matcha-sea [GTK2/3] ████████ ████████ ████████ Icons: Papirus-Dark-Maia [GTK2/3] Terminal: gnome-terminal CPU: Intel i5-9500 (6) @ 4.400GHz GPU: Intel UHD Graphics 630 Memory: 5578MiB / 15846MiB ``` ```bash 1. linux编译我的环境按照官方文档 snap出错 不知道啥问题 multipass lxd 都试过 打包资料很少没折腾出来 不知道ubuntu能行吗 # cat snap/snapcraft.yaml name: colatea-rename-app # you probably want to 'snapcraft register ' base: core18 # the base snap is the execution environment for this snap version: '0.1.0' # just for humans, typically '1.2+git' or '1.3.2' summary: Single-line elevator pitch for your amazing snap # 79 char long summary description: Modify the file name in bulk grade: stable # must be 'stable' to release into candidate/stable channels confinement: strict # use 'strict' once you have the right plugs and slots parts: colatea-rename-app: # See 'snapcraft plugins' plugin: nil command: colatea_rename extensions: [flutter-master] # Where "master" defines which Flutter channel to use for the build ``` ```bash 2. 试了试 appimage-builder 工具 ,也是最后打包的时候报错,放弃了,卡在 pacman -S ...地方 https://appimage-builder.readthedocs.io/en/latest/examples/flutter.html https://appimage-builder.readthedocs.io/en/latest/intro/install.html ``` ```bash 3. 采用以前的方案go-flutter打包成功 使用hover工具,可能一直在写go,折腾环境比较熟悉把,终于成功了 相对比较简单,go环境配置好,安装好hover就基本OK hover建议flutter切beta,但是我用的stable也没有问题 https://github.com/go-flutter-desktop/go-flutter ``` ## 完成进度 ```bash 功能:支持正则替换的批量改名工具 # 100% 基本使用(首页、配置、关于) # 0% 要做把数字放到最前面 # 100% 没做复制到新目录 # 100% 正则的例子要写 v0.1.0 # 0% snap仓库发布 # 100% windows打包完成 # 100% linux采用go-flutter打包appimage 已知问题 # 0% 用go-flutter打包appimage后,flutter的url_launcher补工作 ``` ## 谢谢