Skip to content

Commit aa2befd

Browse files
committed
refactor: 改名 oflow -> next-flow
1 parent 37bbaab commit aa2befd

File tree

12 files changed

+43
-37
lines changed

12 files changed

+43
-37
lines changed

.github/workflows/deploy.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,20 +33,20 @@ jobs:
3333
- name: Install Dependencies
3434
run: bun install --frozen-lockfile
3535

36-
- name: Clone oflow-interface
36+
- name: Clone next-flow-interface
3737
run: |
3838
cd ../
39-
git clone https://github.com/O-Flow/oflow-interface.git
39+
git clone https://github.com/n-flow/next-flow-interface.git
4040
41-
- name: Build oflow-interface
41+
- name: Build next-flow-interface
4242
run: |
43-
cd ../oflow-interface
43+
cd ../next-flow-interface
4444
bun install --frozen-lockfile
4545
bun run build
4646
bun link
4747
48-
- name: Link oflow-interface to oflow-space
49-
run: bun link oflow-interface
48+
- name: Link next-flow-interface to next-flow-space
49+
run: bun link next-flow-interface
5050

5151
- name: Run Unit Tests
5252
run: bun run test
@@ -71,8 +71,8 @@ jobs:
7171
OSS_REGION: ${{ secrets.OSS_REGION }}
7272
OSS_BUCKET: ${{ secrets.OSS_BUCKET }}
7373
run: |
74-
echo "::notice::Uploading to oss://${OSS_BUCKET}/nflow/plugins/${PLUGIN_ID}/v${VERSION}/"
75-
ossutil cp -r ./dist/ oss://${OSS_BUCKET}/nflow/plugins/${PLUGIN_ID}/v${VERSION}/ --force
74+
echo "::notice::Uploading to oss://${OSS_BUCKET}/public/plugins/${PLUGIN_ID}/v${VERSION}/"
75+
ossutil cp -r ./dist/ oss://${OSS_BUCKET}/public/plugins/${PLUGIN_ID}/v${VERSION}/ --force
7676
echo ""
77-
echo "::notice::Uploading to oss://${OSS_BUCKET}/nflow/plugins/${PLUGIN_ID}/latest/"
78-
ossutil cp -r ./dist/ oss://${OSS_BUCKET}/nflow/plugins/${PLUGIN_ID}/latest/ --force
77+
echo "::notice::Uploading to oss://${OSS_BUCKET}/public/plugins/${PLUGIN_ID}/latest/"
78+
ossutil cp -r ./dist/ oss://${OSS_BUCKET}/public/plugins/${PLUGIN_ID}/latest/ --force

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
# ofp-template-drawer
2-
O-Flow Plugin Template Drawer
1+
# nfp-template-drawer
2+
Next-Flow Plugin Template Drawer

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "ofp-template-drawer",
2+
"name": "nfp-template-drawer",
33
"version": "1.0.0",
44
"description": "",
55
"plugin": {
@@ -25,7 +25,7 @@
2525
"format:check": "prettier --check ."
2626
},
2727
"keywords": [],
28-
"author": "O FLow",
28+
"author": "Next FLow",
2929
"license": "Apache-2.0",
3030
"dependencies": {
3131
"@babylonjs/core": "7.41.1",

scripts/commit.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
#!/usr/bin/env node
22

3-
const readline = require('readline')
43
const { execSync } = require('child_process')
5-
const path = require('path')
64
const fs = require('fs')
5+
const path = require('path')
6+
const readline = require('readline')
77

88
const packageJson = require('../package.json');
99

1010
const PROJECT_PATH = path.resolve(__dirname, '../')
11-
const ACTIONS_URL = 'https://github.com/O-FLOW/' + packageJson.name + '/actions'
11+
const ACTIONS_URL = 'https://github.com/n-flow/' + packageJson.name + '/actions'
1212

1313
function checkPackageJson(projectPath) {
1414
if (!fs.existsSync(path.join(projectPath, 'package.json'))) {

scripts/copy-file-to-all-plugins.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
const path = require('path')
21
const { execSync } = require('child_process')
32
const fs = require('fs')
3+
const path = require('path')
44

55

66
const GENERAL_FILE_LIST = [
@@ -17,7 +17,7 @@ const GENERAL_FILE_LIST = [
1717
'webpack.production.config.js',
1818
]
1919

20-
const COMMIT_MESSAGE = 'chore: sync files from ofp-template'
20+
const COMMIT_MESSAGE = 'chore: sync files from nfp-template'
2121

2222

2323
const pluginsPath = path.resolve(__dirname, '../../')
@@ -30,7 +30,7 @@ const pluginsNeedUpdate = []
3030

3131
fs.readdirSync(pluginsPath).forEach(file => {
3232
const fullPath = path.join(pluginsPath, file)
33-
if (fs.statSync(fullPath).isDirectory() && file.startsWith('ofp-') && fullPath !== currentPath) {
33+
if (fs.statSync(fullPath).isDirectory() && file.startsWith('nfp-') && fullPath !== currentPath) {
3434
pluginsList.push(fullPath)
3535
}
3636
})

src/api.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import {
2-
OfpApi, SpaceServiceApi,
2+
NfpApi, SpaceServiceApi,
33
AntCheckboxProps, AntColorProps, AntNumberProps, AntSelectProps, AntSwitchProps,
44
RsdButtonProps, RsdCheckboxProps, RsdColorProps, RsdSelectProps, RsdFileSelectProps, RsdInputProps, RsdMentionsProps, RsdNoneProps, RsdNumberProps, RsdNumberListProps, RsdSwitchProps, RsdTitleProps,RsdCheckableButtonProps,
55
SpanProps,
@@ -55,7 +55,8 @@ import {
5555
RvMaterialAttributeApi,
5656
ThemeServiceApi,
5757
ResourcePreviewProps,
58-
} from "oflow-interface";
58+
} from "next-flow-interface";
59+
5960
import type { FunctionComponent } from "react";
6061

6162
export let rvLocationAttribute: RvLocationAttributeApi
@@ -164,7 +165,7 @@ export let sleep: (time: number) => FunctionComponent<any>
164165

165166

166167
export function loadApi() {
167-
const api = (window as any).ofpConnector.getOfpApi() as OfpApi
168+
const api = (window as any).nfpConnector.getNfpApi() as NfpApi
168169

169170
rvLocationAttribute = api.services.attributes.rvLocationAttribute
170171
rvLabelAttribute = api.services.attributes.rvLabelAttribute

src/drawer/drawer.tsx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
1+
import clsx from "clsx";
2+
import {ThemeColor} from "next-flow-interface";
13
import React from "react";
2-
import styles from "./drawer.module.sass"
4+
35
import {rss, ScrollBar, ThemeProvider} from "../api";
4-
import clsx from "clsx";
5-
import {ThemeColor} from "oflow-interface";
6+
7+
import styles from "./drawer.module.sass"
68

79
export default function Drawer() {
810

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ import Plugin from "./plugin";
22

33
export { Plugin }
44

5-
window.ofpConnector.install(new Plugin())
5+
window.nfpConnector.install(new Plugin())

src/plugin.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1+
import {IconPluginPosition, PluginType, ThemeColor,DrawerPlugin} from 'next-flow-interface'
2+
import React from 'react';
3+
14
import packageJson from '../package.json'
2-
import {IconPluginPosition, PluginType, ThemeColor} from 'oflow-interface'
3-
import {DrawerPlugin} from "oflow-interface";
5+
46
import {loadApi} from "./api";
5-
import React from 'react';
67
import Drawer from "./drawer/drawer";
78

89

src/types/global.d.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11

22
declare module '*.module.css' {
3-
const classes: { [key: string]: string };
3+
const classes: Record<string, string>;
44
export default classes;
55
}
66

77
declare module '*.module.scss' {
8-
const classes: { [key: string]: string };
8+
const classes: Record<string, string>;
99
export default classes;
1010
}
1111

1212
declare module '*.module.sass' {
13-
const classes: { [key: string]: string };
13+
const classes: Record<string, string>;
1414
export default classes;
1515
}
1616

1717
declare interface Window {
18-
ofpConnector: {
18+
nfpConnector: {
1919
install: (plugin: any) => void
2020
}
2121
}

0 commit comments

Comments
 (0)