From 4da8901139a7f103ab29d6b8824f25e549421f47 Mon Sep 17 00:00:00 2001 From: Will Chavez <98856968+williamch-ms@users.noreply.github.com> Date: Fri, 13 Jan 2023 15:34:10 -0800 Subject: [PATCH] Temporarily removing font-building steps. (#539) * Disabled Flutter build, removing font statements from the React build process. --- .github/workflows/bump-version.yml | 28 ++++++------ .github/workflows/pr.yml | 70 ++++++++++++++--------------- .github/workflows/publish.yml | 72 +++++++++++++++--------------- packages/react-icons/package.json | 12 +---- 4 files changed, 86 insertions(+), 96 deletions(-) diff --git a/.github/workflows/bump-version.yml b/.github/workflows/bump-version.yml index 434b60577c..62cfce8ff6 100644 --- a/.github/workflows/bump-version.yml +++ b/.github/workflows/bump-version.yml @@ -41,17 +41,17 @@ jobs: sed -i.bk -r "s/[0-9]+\.[0-9]+\.[0-9]+/$NEW_VERSION/g" ios/FluentIcons.podspec rm ios/FluentIcons.podspec.bk - # Needs to be "-E" instead of "-r" on macOS - - name: Replace version number in flutter/CHANGELOG.md - run: | - sed -i.bk -r "s/[0-9]+\.[0-9]+\.[0-9]+/$NEW_VERSION/g" flutter/CHANGELOG.md - rm flutter/CHANGELOG.md.bk + # # Needs to be "-E" instead of "-r" on macOS + # - name: Replace version number in flutter/CHANGELOG.md + # run: | + # sed -i.bk -r "s/[0-9]+\.[0-9]+\.[0-9]+/$NEW_VERSION/g" flutter/CHANGELOG.md + # rm flutter/CHANGELOG.md.bk - # Needs to be "-E" instead of "-r" on macOS - - name: Replace version number in flutter/pubspec.yaml - run: | - sed -i.bk -r "s/version: [0-9]+\.[0-9]+\.[0-9]+/version: $NEW_VERSION/g" flutter/pubspec.yaml - rm flutter/pubspec.yaml.bk + # # Needs to be "-E" instead of "-r" on macOS + # - name: Replace version number in flutter/pubspec.yaml + # run: | + # sed -i.bk -r "s/version: [0-9]+\.[0-9]+\.[0-9]+/version: $NEW_VERSION/g" flutter/pubspec.yaml + # rm flutter/pubspec.yaml.bk # Needs to be "-E" instead of "-r" on macOS - name: Replace version number in svg-icons/package.json @@ -66,10 +66,10 @@ jobs: rm packages/react-icons/package.json.bk # Needs to be "-E" instead of "-r" on macOS - - name: Replace version number in react-icons-font-subsetting-webpack-plugin/package.json - run: | - sed -i.bk -r "s/\"version\": \"[0-9]+\.[0-9]+\.[0-9]+\"/\"version\": \"$NEW_VERSION\"/g" packages/react-icons-font-subsetting-webpack-plugin/package.json - rm packages/react-icons-font-subsetting-webpack-plugin/package.json.bk + # - name: Replace version number in react-icons-font-subsetting-webpack-plugin/package.json + # run: | + # sed -i.bk -r "s/\"version\": \"[0-9]+\.[0-9]+\.[0-9]+\"/\"version\": \"$NEW_VERSION\"/g" packages/react-icons-font-subsetting-webpack-plugin/package.json + # rm packages/react-icons-font-subsetting-webpack-plugin/package.json.bk - name: Config git credentials run: git config user.email "flubuild@microsoft.com" && git config user.name "Fluent Build System" diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 0dca2aeba7..09883d64aa 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -79,35 +79,35 @@ jobs: run: python3 generate_build_gn_android.py working-directory: importer - build-flutter: - name: Build Flutter library - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - - name: Use Node 18 - uses: actions/setup-node@v1 - with: - node-version: 18.x - - - run: npm install - - - name: Run generate script - run: npm run deploy:flutter - working-directory: importer - - # Build Flutter library - # The name should be same as the package name on pub.dev - # Tokens are placeholder strings in order for the action to run on forked repos. - - name: 'fluentui_system_icons' - uses: k-paxian/dart-package-publisher@master - with: - relativePath: 'flutter' - skipTests: true - dryRunOnly: true - accessToken: "placeholder" - refreshToken: "placeholder" + # build-flutter: + # name: Build Flutter library + # runs-on: ubuntu-latest + + # steps: + # - uses: actions/checkout@v2 + + # - name: Use Node 18 + # uses: actions/setup-node@v1 + # with: + # node-version: 18.x + + # - run: npm install + + # - name: Run generate script + # run: npm run deploy:flutter + # working-directory: importer + + # # Build Flutter library + # # The name should be same as the package name on pub.dev + # # Tokens are placeholder strings in order for the action to run on forked repos. + # - name: 'fluentui_system_icons' + # uses: k-paxian/dart-package-publisher@master + # with: + # relativePath: 'flutter' + # skipTests: true + # dryRunOnly: true + # accessToken: "placeholder" + # refreshToken: "placeholder" build-svg: name: Build svg library @@ -145,10 +145,10 @@ jobs: npm run build working-directory: packages/react-icons - - run: | - npm run build - working-directory: packages/react-icons-font-subsetting-webpack-plugin + # - run: | + # npm run build + # working-directory: packages/react-icons-font-subsetting-webpack-plugin - - run: | - npm run test - working-directory: packages/react-icons-font-subsetting-webpack-plugin + # - run: | + # npm run test + # working-directory: packages/react-icons-font-subsetting-webpack-plugin diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 8b930b4a5a..59434289db 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -56,18 +56,18 @@ jobs: working-directory: importer ## Flutter - - name: Run Flutter generate script - run: npm run deploy:flutter - working-directory: importer - - # The name should be same as the package name on pub.dev - - name: 'fluentui_system_icons' - uses: k-paxian/dart-package-publisher@master - with: - relativePath: 'flutter' - skipTests: true - accessToken: ${{ secrets.FLUTTER_OAUTH_ACCESS_TOKEN }} - refreshToken: ${{ secrets.FLUTTER_OAUTH_REFRESH_TOKEN }} + # - name: Run Flutter generate script + # run: npm run deploy:flutter + # working-directory: importer + + # # The name should be same as the package name on pub.dev + # - name: 'fluentui_system_icons' + # uses: k-paxian/dart-package-publisher@master + # with: + # relativePath: 'flutter' + # skipTests: true + # accessToken: ${{ secrets.FLUTTER_OAUTH_ACCESS_TOKEN }} + # refreshToken: ${{ secrets.FLUTTER_OAUTH_REFRESH_TOKEN }} ## Publish # Needs to be "-E" instead of "-r" on macOS @@ -88,17 +88,17 @@ jobs: sed -i.bk -r "s/[0-9]+\.[0-9]+\.[0-9]+/$NEW_VERSION/g" ios/FluentIcons.podspec rm ios/FluentIcons.podspec.bk - # Needs to be "-E" instead of "-r" on macOS - - name: Replace version number in flutter/CHANGELOG.md - run: | - sed -i.bk -r "s/[0-9]+\.[0-9]+\.[0-9]+/$NEW_VERSION/g" flutter/CHANGELOG.md - rm flutter/CHANGELOG.md.bk + # # Needs to be "-E" instead of "-r" on macOS + # - name: Replace version number in flutter/CHANGELOG.md + # run: | + # sed -i.bk -r "s/[0-9]+\.[0-9]+\.[0-9]+/$NEW_VERSION/g" flutter/CHANGELOG.md + # rm flutter/CHANGELOG.md.bk - # Needs to be "-E" instead of "-r" on macOS - - name: Replace version number in flutter/pubspec.yaml - run: | - sed -i.bk -r "s/version: [0-9]+\.[0-9]+\.[0-9]+/version: $NEW_VERSION/g" flutter/pubspec.yaml - rm flutter/pubspec.yaml.bk + # # Needs to be "-E" instead of "-r" on macOS + # - name: Replace version number in flutter/pubspec.yaml + # run: | + # sed -i.bk -r "s/version: [0-9]+\.[0-9]+\.[0-9]+/version: $NEW_VERSION/g" flutter/pubspec.yaml + # rm flutter/pubspec.yaml.bk # Needs to be "-E" instead of "-r" on macOS - name: Replace version number in svg-icons/package.json @@ -118,11 +118,11 @@ jobs: sed -i.bk -r "s/\"version\": \"[0-9]+\.[0-9]+\.[0-9]+(-beta\.[0-9]+)?(-rc\.[0-9]+)?\"/\"version\": \"$REACT_VERSION\"/g" packages/react-icons/package.json rm packages/react-icons/package.json.bk - # Needs to be "-E" instead of "-r" on macOS - - name: Replace version number in react-icons-font-subsetting-webpack-plugin/package.json - run: | - sed -i.bk -r "s/\"version\": \"[0-9]+\.[0-9]+\.[0-9]+(-beta\.[0-9]+)?(-rc\.[0-9]+)?\"/\"version\": \"$REACT_VERSION\"/g" packages/react-icons-font-subsetting-webpack-plugin/package.json - rm packages/react-icons-font-subsetting-webpack-plugin/package.json.bk + # # Needs to be "-E" instead of "-r" on macOS + # - name: Replace version number in react-icons-font-subsetting-webpack-plugin/package.json + # run: | + # sed -i.bk -r "s/\"version\": \"[0-9]+\.[0-9]+\.[0-9]+(-beta\.[0-9]+)?(-rc\.[0-9]+)?\"/\"version\": \"$REACT_VERSION\"/g" packages/react-icons-font-subsetting-webpack-plugin/package.json + # rm packages/react-icons-font-subsetting-webpack-plugin/package.json.bk - name: Install dependencies run: npm install @@ -142,10 +142,10 @@ jobs: npm run build working-directory: packages/react-icons - - name: Build Webpack plugin library - run: | - npm run build - working-directory: packages/react-icons-font-subsetting-webpack-plugin + # - name: Build Webpack plugin library + # run: | + # npm run build + # working-directory: packages/react-icons-font-subsetting-webpack-plugin - uses: JS-DevTools/npm-publish@v1 with: @@ -165,11 +165,11 @@ jobs: access: public package: packages/react-icons/package.json - - uses: JS-DevTools/npm-publish@v1 - with: - token: ${{ secrets.NPM_TOKEN }} - access: public - package: packages/react-icons-font-subsetting-webpack-plugin/package.json + # - uses: JS-DevTools/npm-publish@v1 + # with: + # token: ${{ secrets.NPM_TOKEN }} + # access: public + # package: packages/react-icons-font-subsetting-webpack-plugin/package.json ## Android - name: Run Android generate script diff --git a/packages/react-icons/package.json b/packages/react-icons/package.json index 1ba9a79b0c..25495524ff 100644 --- a/packages/react-icons/package.json +++ b/packages/react-icons/package.json @@ -25,7 +25,7 @@ "rollup": "node ./generateRollup.js", "optimize": "svgo --config svgo.config.js --folder=./intermediate --precision=2", "unfill": "find ./intermediate -type f -name \"*.svg\" -exec sed -i.bak 's/fill=\"none\"//g' {} \\; && find ./intermediate -type f -name \"*.bak\" -delete", - "build": "npm run copy && npm run generate:font && npm run optimize && npm run unfill && npm run convert:svg && npm run convert:fonts && npm run cleanSvg && npm run build:esm && npm run build:cjs && npm run copy:font-files", + "build": "npm run copy && npm run optimize && npm run unfill && npm run convert:svg && npm run cleanSvg && npm run build:esm && npm run build:cjs", "build:cjs": "tsc --module commonjs --outDir lib-cjs && babel lib-cjs --out-dir lib-cjs", "build:esm": "tsc && babel lib --out-dir lib" }, @@ -59,22 +59,12 @@ ], "exports": { ".": { - "fluentIconFont": { - "types": "./lib/fonts/index.d.ts", - "import": "./lib/fonts/index.js", - "require": "./lib-cjs/fonts/index.js" - }, "default": { "types": "./lib/index.d.ts", "import": "./lib/index.js", "require": "./lib-cjs/index.js" } }, - "./lib/fonts": { - "types": "./lib/fonts/index.d.ts", - "import": "./lib/fonts/index.js", - "require": "./lib-cjs/fonts/index.js" - }, "./lib/svg": { "types": "./lib/index.d.ts", "import": "./lib/index.js",