caravel/.github/workflows/auto-update-caravel-lite.yml

58 lines
2.8 KiB
YAML
Raw Normal View History

2021-12-15 22:20:37 -06:00
# SPDX-FileCopyrightText: 2020 Efabless Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# SPDX-License-Identifier: Apache-2.0
# This is a workflow to automatically update caravel-lite whenever caravel master is updated.
name: Auto Update Caravel Lite
# Controls when the action will run.
on:
# Trigger the workflow on push to master branch
push:
branches:
2022-01-07 11:04:04 -06:00
- main
2021-12-15 22:20:37 -06:00
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
2021-12-15 22:20:37 -06:00
- name: Install git-filter-repo
run: pip install git-filter-repo
- name: Update Caravel Lite
run: |
mkdir -p caravel-lite
cd caravel-lite
git config --global user.name 'EF Staff'
git config --global user.email 'github@efabless.com'
2021-12-16 01:25:13 -06:00
git config --global init.defaultBranch main
2021-12-15 22:20:37 -06:00
git init
git checkout -b main
2021-12-17 13:55:08 -06:00
git remote add parent https://github.com/efabless/caravel
2021-12-16 01:25:13 -06:00
git pull parent main
2021-12-15 22:20:37 -06:00
git fetch --all --tags
2022-11-17 01:21:14 -06:00
git filter-repo --path def --path-glob 'signoff/*/openlane-signoff/spef' --path openlane/user_project_wrapper --path openlane/user_analog_project_wrapper --path openlane/Makefile --path gds/user_project_wrapper_empty.gds.gz --path gds/user_analog_project_wrapper_empty.gds.gz --path mag/user_project_wrapper_empty.mag --path mag/user_analog_project_wrapper_empty.mag --path lef/user_project_wrapper_empty.lef --path lef/user_analog_project_wrapper_empty.lef --path verilog/ --path Makefile --path scripts/ --path LICENSE --path manifest --path spi/lvs/run_lvs.sh --path gds/gds2mag-all.sh --path gds/drc_on_gds.tcl --path gds/antenna_on_gds.tcl --path spi/lvs/caravel.spice --path spi/lvs/caravan.spice --force
2021-12-17 13:55:08 -06:00
git remote add caravel_lite https://x-access-token:${{ secrets.EFSTAFF_TOKEN }}@github.com/efabless/caravel-lite
2021-12-15 22:20:37 -06:00
git push --force caravel_lite main
git push -f --tags caravel_lite main