Skip to content
Snippets Groups Projects
Select Git revision
  • d0f0f57ba48879c5272996dd7de3b77006f45c2e
  • main default
2 results

socrepo-init

Blame
  • Forked from an inaccessible project.
    user avatar
    dam1n19 authored
    d0f0f57b
    History
    socrepo-init 924 B
    #-----------------------------------------------------------------------------
    # SoC Labs socsim script to run required simulation
    # A joint work commissioned on behalf of SoC Labs, under Arm Academic Access license.
    #
    # Contributors
    #
    # David Mapstone (d.a.mapstone@soton.ac.uk)
    #
    # Copyright  2022, SoC Labs (www.soclabs.org)
    #-----------------------------------------------------------------------------
    
    #!/usr/bin/env bash
    
    # Source environment variables for all submodules
    cd $DESIGN_ROOT
    for d in $SOC_TOP_DIR/* ; do
        if [ -e "$d/.git" ]; then
            echo $d
            if [ -f "$d/set_env.sh" ]; then
            # If .git file exists - submodule
                # git config -f .gitmodules submodule.$d.branch main
                git submodule set-branch --branch main $d
            fi
        fi
    done
    git submodule update --remote --recursive
    git submodule foreach --recursive git checkout main
    git restore $DESIGN_ROOT/.gitmodules