Added repo structure
diff --git a/.github/scripts/build/run-set-id.sh b/.github/scripts/build/run-set-id.sh
new file mode 100644
index 0000000..b6e9cfb
--- /dev/null
+++ b/.github/scripts/build/run-set-id.sh
@@ -0,0 +1,38 @@
+#!/bin/bash
+# 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
+
+export UPRJ_ROOT=$(pwd)
+cd ..
+export PDK_ROOT=$(pwd)/pdks
+export CARAVEL_ROOT=$(pwd)/caravel
+export IMAGE_NAME=efabless/openlane:$OPENLANE_TAG
+export USER_ID=00000001
+
+cd $UPRJ_ROOT
+
+# Install full version of caravel
+git clone https://github.com/efabless/caravel --branch develop --depth 1 $CARAVEL_ROOT
+
+LOG_FILE=out.log
+docker run -v $UPRJ_ROOT:$UPRJ_ROOT -v $PDK_ROOT:$PDK_ROOT -v $CARAVEL_ROOT:$CARAVEL_ROOT -e UPRJ_ROOT=$UPRJ_ROOT -e PDK_ROOT=$PDK_ROOT -e CARAVEL_ROOT=$CARAVEL_ROOT -u $(id -u $USER):$(id -g $USER) $IMAGE_NAME bash -c "cd $CARAVEL_ROOT; make uncompress; cd $UPRJ_ROOT; export USER_ID=$USER_ID; make set_user_id | tee $LOG_FILE;"
+
+cnt=$(grep "Done" $LOG_FILE -s | wc -l)
+
+if [[ $cnt -ne 3 ]]; then 
+        exit 2; 
+fi
+
+exit 0
\ No newline at end of file
diff --git a/.github/scripts/build/run-truck.sh b/.github/scripts/build/run-truck.sh
new file mode 100644
index 0000000..84f183b
--- /dev/null
+++ b/.github/scripts/build/run-truck.sh
@@ -0,0 +1,36 @@
+#!/bin/bash
+# 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
+
+export UPRJ_ROOT=$(pwd)
+cd ..
+export PDK_ROOT=$(pwd)/pdks
+export CARAVEL_ROOT=$(pwd)/caravel
+export IMAGE_NAME=efabless/openlane:$OPENLANE_TAG
+
+cd $UPRJ_ROOT
+
+# Install full version of caravel
+git clone https://github.com/efabless/caravel --branch develop --depth 1 $CARAVEL_ROOT
+
+docker run -v $UPRJ_ROOT:$UPRJ_ROOT -v $PDK_ROOT:$PDK_ROOT -v $CARAVEL_ROOT:$CARAVEL_ROOT -e UPRJ_ROOT=$UPRJ_ROOT -e PDK_ROOT=$PDK_ROOT -e CARAVEL_ROOT=$CARAVEL_ROOT -u $(id -u $USER):$(id -g $USER) $IMAGE_NAME bash -c "cd $CARAVEL_ROOT; make uncompress; cd $UPRJ_ROOT; make truck;"
+
+SHIP_FILE=$UPRJ_ROOT/gds/caravan.gds
+
+if test -f "$SHIP_FILE"; then
+    exit 0
+else
+    exit 2
+fi
diff --git a/.github/scripts/build/run-xor.sh b/.github/scripts/build/run-xor.sh
new file mode 100644
index 0000000..e666188
--- /dev/null
+++ b/.github/scripts/build/run-xor.sh
@@ -0,0 +1,39 @@
+#!/bin/bash
+# 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
+
+export UPRJ_ROOT=$(pwd)
+cd ..
+export PDK_ROOT=$(pwd)/pdks
+export CARAVEL_ROOT=$(pwd)/caravel
+export IMAGE_NAME=efabless/openlane:$OPENLANE_TAG
+
+cd $UPRJ_ROOT
+
+# Install full version of caravel
+git clone https://github.com/efabless/caravel --branch develop --depth 1 $CARAVEL_ROOT
+
+LOG_FILE=out.log
+docker run -v $UPRJ_ROOT:$UPRJ_ROOT -v $PDK_ROOT:$PDK_ROOT -v $CARAVEL_ROOT:$CARAVEL_ROOT -e UPRJ_ROOT=$UPRJ_ROOT -e PDK_ROOT=$PDK_ROOT -e CARAVEL_ROOT=$CARAVEL_ROOT -u $(id -u $USER):$(id -g $USER) $IMAGE_NAME bash -c "cd $UPRJ_ROOT; export USER_ID=$USER_ID; make xor-analog-wrapper | tee $LOG_FILE;"
+
+cnt=$(grep -oP '(?<=Total XOR differences = )[0-9]+' $LOG_FILE)
+
+echo "Total XOR differences = $cnt"
+
+if [[ $cnt -ne 0 ]]; then 
+    exit 2; 
+fi
+
+exit 0
diff --git a/.github/scripts/dv/pdkBuild.sh b/.github/scripts/dv/pdkBuild.sh
new file mode 100644
index 0000000..9f9ac93
--- /dev/null
+++ b/.github/scripts/dv/pdkBuild.sh
@@ -0,0 +1,59 @@
+#!/bin/bash
+# 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
+export RUN_ROOT=$(pwd)
+
+
+# By default skip timing since we don't need the libs in any of the CI tests
+export SKIP_TIMING=${1:-1}
+export IMAGE_NAME=efabless/openlane:$OPENLANE_TAG
+docker pull $IMAGE_NAME
+
+cd $RUN_ROOT/..
+export PDK_ROOT=$(pwd)/pdks
+mkdir $PDK_ROOT
+echo $PDK_ROOT
+echo $RUN_ROOT
+cd $RUN_ROOT
+make skywater-pdk
+make skywater-library
+# The following section is for running on the CI.
+# If you're running locally you should replace them with: `make skywater-library`
+# This is because sometimes while setting up the conda env (skywater's make timing) it fails to fetch something
+# Then it exits without retrying. So, here we're retrying, and if something goes wrong it will exit after 5 retries.
+# Section Begin
+if [ $SKIP_TIMING -eq 0 ]; then
+	cnt=0
+	until make skywater-timing; do
+	cnt=$((cnt+1))
+	if [ $cnt -eq 5 ]; then
+		exit 2
+	fi
+	rm -rf $PDK_ROOT/skywater-pdk
+	make skywater-pdk
+	make skywater-library
+	done
+fi
+# Section End
+
+make open_pdks
+docker run -v $RUN_ROOT:/openLANE_flow -v $PDK_ROOT:$PDK_ROOT -e PDK_ROOT=$PDK_ROOT -u $(id -u $USER):$(id -g $USER) $IMAGE_NAME  bash -c "make build-pdk"
+
+rm -rf $PDK_ROOT/open_pdks
+rm -rf $PDK_ROOT/skywater-pdk
+
+echo "done installing"
+cd $RUN_ROOT
+exit 0
\ No newline at end of file
diff --git a/.github/scripts/dv/run-dv-wrapper.sh b/.github/scripts/dv/run-dv-wrapper.sh
new file mode 100644
index 0000000..20bc951
--- /dev/null
+++ b/.github/scripts/dv/run-dv-wrapper.sh
@@ -0,0 +1,77 @@
+#!/bin/bash
+# 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
+
+# comma seperated test ids
+IDS=$1
+# simulation mode : RTL/GL
+SIM_MODE=$2
+
+DV_TEST_IDS=(${IDS//,/ })
+
+export TARGET_PATH=$(pwd)
+export CARAVEL_ROOT=$(pwd)/caravel
+
+if [ ! -d $TARGET_PATH ] 
+then
+    echo "Directory /path/to/dir DOES NOT exists." 
+    exit 9999 
+fi
+
+cd ..
+
+export PDK_ROOT=$(pwd)/pdks
+if [ ! -d $PDK_ROOT ] 
+then
+    echo "Directory /path/to/dir DOES NOT exists." 
+    exit 9999 
+fi
+
+DV_PATH=$TARGET_PATH/verilog/dv
+if [ ! -d $DV_PATH ] 
+then
+    echo "Directory /path/to/dir DOES NOT exists." 
+    exit 9999
+fi
+
+for id in "${DV_TEST_IDS[@]}"
+do 
+    docker run -v $TARGET_PATH:$TARGET_PATH -v $PDK_ROOT:$PDK_ROOT \
+                -v $CARAVEL_ROOT:$CARAVEL_ROOT \
+                -e TARGET_PATH=$TARGET_PATH -e PDK_ROOT=$PDK_ROOT \
+                -e CARAVEL_ROOT=$CARAVEL_ROOT \
+                -u $(id -u $USER):$(id -g $USER) efabless/dv_setup:latest \
+                bash -c "bash $TARGET_PATH/.github/scripts/dv/run-dv.sh $PDK_ROOT $DV_PATH $id $SIM_MODE"
+
+    echo "DONE!"
+
+    VERDICT_FILE=$TARGET_PATH/verilog/dv/$id.out
+
+    if [ -f $VERDICT_FILE ]; then
+        cnt=$(grep "Pass" $VERDICT_FILE -s | wc -l)
+        if ! [[ $cnt ]]; then cnt = 0; fi
+    else
+        echo "DV check failed due to subscript failure. Please review the logs";
+        exit 2;
+    fi
+
+    echo "Verdict: $cnt"
+
+    if [[ $cnt -ne 1 ]]; then 
+        exit 2; 
+    fi
+done
+
+exit 0;
diff --git a/.github/scripts/dv/run-dv.sh b/.github/scripts/dv/run-dv.sh
new file mode 100644
index 0000000..53b7e96
--- /dev/null
+++ b/.github/scripts/dv/run-dv.sh
@@ -0,0 +1,40 @@
+PDK_ROOT=$1
+DV_PATH=$2
+DV_TEST_ID=$3
+SIM_MODE=$4
+
+cd $DV_PATH
+
+## get the name of all subdfolders under verilog/dv 
+ALL_DV_TESTS="$(find * -maxdepth 0 -type d)"
+## convert all ALL_DV_TESTS to an array
+TESTS_ARR=($ALL_DV_TESTS)
+## get length of the TESTS array
+len=${#TESTS_ARR[@]}
+
+## make sure that the test ID is less than the array length
+if [ $DV_TEST_ID -ge $len ]
+then
+    echo "Error: Invalid Test ID"
+    exit 1
+fi
+
+## get the name corresponding to the test ID
+PATTERN=${TESTS_ARR[$DV_TEST_ID]}
+
+OUT_FILE=$DV_PATH/$DV_TEST_ID.out
+
+export SIM=$SIM_MODE
+echo "Running $PATTERN $SIM.."
+logFile=$DV_PATH/$PATTERN.$SIM.dv.out
+cd $PATTERN
+echo $(pwd)
+make 2>&1 | tee $logFile
+grep "Monitor" $logFile >> $OUT_FILE
+make clean
+
+echo "Execution Done on $PATTERN !"
+
+cat $OUT_FILE
+
+exit 0
\ No newline at end of file
diff --git a/.github/scripts/precheck/precheckBuild.sh b/.github/scripts/precheck/precheckBuild.sh
new file mode 100644
index 0000000..7754922
--- /dev/null
+++ b/.github/scripts/precheck/precheckBuild.sh
@@ -0,0 +1,36 @@
+#!/bin/bash
+# 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
+
+# By default build pdk since we don't need the other script for the main purpose
+export SKIP_PDK_BUILD=${1:-0}
+
+export TARGET_PATH=$(pwd)
+git clone https://github.com/efabless/mpw_precheck.git
+
+docker pull efabless/mpw_precheck:latest
+
+
+if [ $SKIP_PDK_BUILD -eq 0 ]; then
+    cd $TARGET_PATH/..
+    export PDK_ROOT=$(pwd)/precheck_pdks
+    mkdir $PDK_ROOT
+    cd $TARGET_PATH/mpw_precheck/dependencies
+    sh build-pdk.sh
+    cd $TARGET_DIR
+
+fi
+
+exit 0
diff --git a/.github/scripts/precheck/run-precheck-drc.sh b/.github/scripts/precheck/run-precheck-drc.sh
new file mode 100644
index 0000000..dd38dc0
--- /dev/null
+++ b/.github/scripts/precheck/run-precheck-drc.sh
@@ -0,0 +1,38 @@
+#!/bin/bash
+# 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
+export TARGET_PATH=$(pwd)
+export CARAVEL_ROOT=$(pwd)/caravel
+cd ..
+export PDK_ROOT=$(pwd)/precheck_pdks
+export PRECHECK_ROOT=$TARGET_PATH/mpw_precheck/
+export OUTPUT_DIRECTORY=$TARGET_PATH/checks
+cd $TARGET_PATH/mpw_precheck/
+
+docker run -v $PRECHECK_ROOT:$PRECHECK_ROOT -v $TARGET_PATH:$TARGET_PATH -v $CARAVEL_ROOT:$CARAVEL_ROOT  -v $PDK_ROOT:$PDK_ROOT -u $(id -u $USER):$(id -g $USER) efabless/mpw_precheck:latest bash -c "cd $PRECHECK_ROOT; python3 mpw_precheck.py magic_drc klayout_offgrid klayout_feol klayout_zeroarea klayout_pin_label_purposes_overlapping_drawing --pdk_root $PDK_ROOT --input_directory $TARGET_PATH --caravel_root $CARAVEL_ROOT --output_directory $OUTPUT_DIRECTORY"
+output=$OUTPUT_DIRECTORY/logs/precheck.log
+
+gzipped_file=$OUTPUT_DIRECTORY/logs/precheck.log.gz
+
+if [[ -f $gzipped_file ]]; then
+    gzip -d $gzipped_file
+fi
+
+grep "Violation Message" $output
+
+cnt=$(grep -c "All Checks Passed" $output)
+if ! [[ $cnt ]]; then cnt=0; fi
+if [[ $cnt -eq 1 ]]; then exit 0; fi
+exit 2
\ No newline at end of file
diff --git a/.github/scripts/precheck/run-precheck.sh b/.github/scripts/precheck/run-precheck.sh
new file mode 100644
index 0000000..66d5da6
--- /dev/null
+++ b/.github/scripts/precheck/run-precheck.sh
@@ -0,0 +1,38 @@
+#!/bin/bash
+# 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
+export TARGET_PATH=$(pwd)
+export CARAVEL_ROOT=$(pwd)/caravel
+cd ..
+export PDK_ROOT=$(pwd)/precheck_pdks
+export PRECHECK_ROOT=$TARGET_PATH/mpw_precheck/
+export OUTPUT_DIRECTORY=$TARGET_PATH/checks
+cd $TARGET_PATH/mpw_precheck/
+
+docker run -v $PRECHECK_ROOT:$PRECHECK_ROOT -v $TARGET_PATH:$TARGET_PATH -v $PDK_ROOT:$PDK_ROOT -v $CARAVEL_ROOT:$CARAVEL_ROOT -u $(id -u $USER):$(id -g $USER) efabless/mpw_precheck:latest bash -c " cd $PRECHECK_ROOT ; python3 mpw_precheck.py license yaml manifest makefile consistency xor --pdk_root $PDK_ROOT --input_directory $TARGET_PATH --caravel_root $CARAVEL_ROOT --output_directory $OUTPUT_DIRECTORY"
+output=$OUTPUT_DIRECTORY/logs/precheck.log
+
+gzipped_file=$OUTPUT_DIRECTORY/logs/precheck.log.gz
+
+if [[ -f $gzipped_file ]]; then
+    gzip -d $gzipped_file
+fi
+
+grep "Violation Message" $output
+
+cnt=$(grep -c "All Checks Passed" $output)
+if ! [[ $cnt ]]; then cnt=0; fi
+if [[ $cnt -eq 1 ]]; then exit 0; fi
+exit 2
diff --git a/.github/workflows/auto_update_submodule.yml b/.github/workflows/auto_update_submodule.yml
new file mode 100644
index 0000000..7219ddf
--- /dev/null
+++ b/.github/workflows/auto_update_submodule.yml
@@ -0,0 +1,41 @@
+    
+name: 'Auto-update Submodules'
+
+on:
+  workflow_dispatch:
+  schedule:
+    - cron: "0 0 * * *"
+
+jobs:
+  sync:
+    name: 'Auto-update Submodules'
+    runs-on: ubuntu-latest
+
+    # Use the Bash shell regardless whether the GitHub Actions runner is ubuntu-latest, macos-latest, or windows-latest
+    defaults:
+      run:
+        shell: bash
+
+    steps:
+    # Checkout the repository to the GitHub Actions runner
+    - name: Checkout
+      uses: actions/checkout@v2
+      with:
+        submodules: true
+    
+    # Git config
+    - name: Git Configurations
+      run: |
+        git config --global user.name 'Git bot'
+        git config --global user.email 'bot@noreply.github.com'
+        
+    # Update references
+    - name: Git Sumbodule Update
+      run: |
+        git submodule update --init --recursive
+        git submodule update --remote --recursive
+
+    - name: Commit update
+      run: |
+        git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
+        git commit -am "Auto updated submodule references" && git push || echo "No changes to commit"
diff --git a/.github/workflows/caravan_build.yml b/.github/workflows/caravan_build.yml
new file mode 100644
index 0000000..800c030
--- /dev/null
+++ b/.github/workflows/caravan_build.yml
@@ -0,0 +1,79 @@
+name: Caravan Build
+
+
+on:
+    # Runs on Every Push
+    push:
+    # Runs on Pull Requests
+    pull_request:
+    workflow_dispatch:
+
+jobs:
+  make_truck:
+    runs-on: ubuntu-latest
+    steps:
+       - uses: actions/checkout@v2
+         with:
+          submodules: 'true'
+      
+       - name: Set up QEMU
+         uses: docker/setup-qemu-action@v1
+
+       - name: Set up Docker Buildx
+         uses: docker/setup-buildx-action@v1
+        
+       - name: Install The PDK
+         run:  bash ${GITHUB_WORKSPACE}/.github/scripts/dv/pdkBuild.sh
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
+
+       - name: Run make truck
+         run: bash ${GITHUB_WORKSPACE}/.github/scripts/build/run-truck.sh 
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
+          
+  set_user_id:
+    runs-on: ubuntu-latest
+    steps:
+       - uses: actions/checkout@v2
+         with:
+          submodules: 'true'
+      
+       - name: Set up QEMU
+         uses: docker/setup-qemu-action@v1
+
+       - name: Set up Docker Buildx
+         uses: docker/setup-buildx-action@v1
+        
+       - name: Install The PDK
+         run:  bash ${GITHUB_WORKSPACE}/.github/scripts/dv/pdkBuild.sh
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
+
+       - name: Run Set User ID
+         run: bash ${GITHUB_WORKSPACE}/.github/scripts/build/run-set-id.sh 
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
+
+  xor_wrapper:
+    runs-on: ubuntu-latest
+    steps:
+       - uses: actions/checkout@v2
+         with:
+          submodules: 'true'
+      
+       - name: Set up QEMU
+         uses: docker/setup-qemu-action@v1
+
+       - name: Set up Docker Buildx
+         uses: docker/setup-buildx-action@v1
+        
+       - name: Install The PDK
+         run:  bash ${GITHUB_WORKSPACE}/.github/scripts/dv/pdkBuild.sh
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
+
+       - name: Run XOR Check
+         run: bash ${GITHUB_WORKSPACE}/.github/scripts/build/run-xor.sh 
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
diff --git a/.github/workflows/user_project_ci.yml b/.github/workflows/user_project_ci.yml
new file mode 100644
index 0000000..a7cb6e8
--- /dev/null
+++ b/.github/workflows/user_project_ci.yml
@@ -0,0 +1,100 @@
+name: CI
+
+
+on:
+    # Runs on Every Push
+    push:
+    # Runs on Pull Requests
+    pull_request:
+    workflow_dispatch:
+
+jobs:
+  precheck:
+    runs-on: ubuntu-latest
+    timeout-minutes: 720
+    steps:
+      - uses: actions/checkout@v2
+        with:
+          submodules: 'true'
+
+      - name: Set up QEMU
+        uses: docker/setup-qemu-action@v1
+
+      - name: Set up Docker Buildx
+        uses: docker/setup-buildx-action@v1
+
+      - name: Install The Precheck
+        run: sh ${GITHUB_WORKSPACE}/.github/scripts/precheck/precheckBuild.sh
+
+      - name: Run The Precheck
+        run: bash ${GITHUB_WORKSPACE}/.github/scripts/precheck/run-precheck.sh
+  
+  precheck-drc:
+    timeout-minutes: 720
+    runs-on: ubuntu-latest
+    steps:
+      - uses: actions/checkout@v2
+        with:
+          submodules: 'true'
+
+      - name: Set up QEMU
+        uses: docker/setup-qemu-action@v1
+
+      - name: Set up Docker Buildx
+        uses: docker/setup-buildx-action@v1
+
+      - name: Install The Precheck
+        run: sh ${GITHUB_WORKSPACE}/.github/scripts/precheck/precheckBuild.sh
+
+      - name: Run The Precheck
+        run: bash ${GITHUB_WORKSPACE}/.github/scripts/precheck/run-precheck-drc.sh
+  
+  dv_rtl:
+    runs-on: ubuntu-latest
+    steps:
+       - uses: actions/checkout@v2
+         with:
+          submodules: 'true'
+      
+       - name: Set up QEMU
+         uses: docker/setup-qemu-action@v1
+
+       - name: Set up Docker Buildx
+         uses: docker/setup-buildx-action@v1
+        
+       - name: Install The PDK
+         run:  bash ${GITHUB_WORKSPACE}/.github/scripts/dv/pdkBuild.sh
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
+          
+       - name: Install The Dockerized DV Setup
+         run:  docker pull efabless/dv_setup:latest
+       
+       - name: Run DV tests
+         # Run test number 0,1,2,3,4 in one job                            <test-ids>   <sim-mode>
+         run: bash ${GITHUB_WORKSPACE}/.github/scripts/dv/run-dv-wrapper.sh 0             RTL
+
+  dv_gl:
+    runs-on: ubuntu-latest
+    steps:
+       - uses: actions/checkout@v2
+         with:
+          submodules: 'true'
+      
+       - name: Set up QEMU
+         uses: docker/setup-qemu-action@v1
+
+       - name: Set up Docker Buildx
+         uses: docker/setup-buildx-action@v1
+        
+       - name: Install The PDK
+         run:  bash ${GITHUB_WORKSPACE}/.github/scripts/dv/pdkBuild.sh
+         env: 
+          OPENLANE_TAG:  2021.09.16_03.28.21
+          
+       - name: Install The Dockerized DV Setup
+         run:  docker pull efabless/dv_setup:latest
+       
+       - name: Run DV tests
+         # Run test number 0,1,2,3,4 in one job                             <test-ids>   <sim-mode>
+         run: bash ${GITHUB_WORKSPACE}/.github/scripts/dv/run-dv-wrapper.sh 0              GL
\ No newline at end of file
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..d97988b
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,177 @@
+# 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
+
+CARAVEL_ROOT?=$(PWD)/caravel
+PRECHECK_ROOT?=${HOME}/mpw_precheck
+SIM ?= RTL
+
+# Install lite version of caravel, (1): caravel-lite, (0): caravel
+CARAVEL_LITE?=1
+
+ifeq ($(CARAVEL_LITE),1) 
+	CARAVEL_NAME := caravel-lite
+	CARAVEL_REPO := https://github.com/efabless/caravel-lite 
+	CARAVEL_BRANCH := main
+else
+	CARAVEL_NAME := caravel
+	CARAVEL_REPO := https://github.com/efabless/caravel 
+	CARAVEL_BRANCH := master
+endif
+
+# Install caravel as submodule, (1): submodule, (0): clone
+SUBMODULE?=1
+
+# Include Caravel Makefile Targets
+.PHONY: % : check-caravel
+%: 
+	export CARAVEL_ROOT=$(CARAVEL_ROOT) && $(MAKE) -f $(CARAVEL_ROOT)/Makefile $@
+
+# Verify Target for running simulations
+.PHONY: verify
+verify:
+	cd ./verilog/dv/ && \
+	export SIM=${SIM} && \
+		$(MAKE) -j$(THREADS)
+
+# Install DV setup
+.PHONY: simenv
+simenv:
+	docker pull efabless/dv_setup:latest
+
+PATTERNS=$(shell cd verilog/dv && find * -maxdepth 0 -type d)
+DV_PATTERNS = $(foreach dv, $(PATTERNS), verify-$(dv))
+TARGET_PATH=$(shell pwd)
+VERIFY_COMMAND="cd ${TARGET_PATH}/verilog/dv/$* && export SIM=${SIM} && make"
+$(DV_PATTERNS): verify-% : ./verilog/dv/% 
+	docker run -v ${TARGET_PATH}:${TARGET_PATH} -v ${PDK_ROOT}:${PDK_ROOT} \
+                -v ${CARAVEL_ROOT}:${CARAVEL_ROOT} \
+                -e TARGET_PATH=${TARGET_PATH} -e PDK_ROOT=${PDK_ROOT} \
+                -e CARAVEL_ROOT=${CARAVEL_ROOT} \
+                -u $(id -u $$USER):$(id -g $$USER) efabless/dv_setup:latest \
+                sh -c $(VERIFY_COMMAND)
+				
+# Openlane Makefile Targets
+BLOCKS = $(shell cd openlane && find * -maxdepth 0 -type d)
+.PHONY: $(BLOCKS)
+$(BLOCKS): %:
+	cd openlane && $(MAKE) $*
+
+# Install caravel
+.PHONY: install
+install:
+ifeq ($(SUBMODULE),1)
+	@echo "Installing $(CARAVEL_NAME) as a submodule.."
+# Convert CARAVEL_ROOT to relative path because .gitmodules doesn't accept '/'
+	$(eval CARAVEL_PATH := $(shell realpath --relative-to=$(shell pwd) $(CARAVEL_ROOT)))
+	@if [ ! -d $(CARAVEL_ROOT) ]; then git submodule add --name $(CARAVEL_NAME) $(CARAVEL_REPO) $(CARAVEL_PATH); fi
+	@git submodule update --init
+	@cd $(CARAVEL_ROOT); git checkout $(CARAVEL_BRANCH)
+	$(MAKE) simlink
+else
+	@echo "Installing $(CARAVEL_NAME).."
+	@git clone $(CARAVEL_REPO) $(CARAVEL_ROOT)
+	@cd $(CARAVEL_ROOT); git checkout $(CARAVEL_BRANCH)
+endif
+
+# Create symbolic links to caravel's main files
+.PHONY: simlink
+simlink: check-caravel
+### Symbolic links relative path to $CARAVEL_ROOT 
+	$(eval MAKEFILE_PATH := $(shell realpath --relative-to=openlane $(CARAVEL_ROOT)/openlane/Makefile))
+	mkdir -p openlane
+	cd openlane &&\
+	ln -sf $(MAKEFILE_PATH) Makefile
+
+# Update Caravel
+.PHONY: update_caravel
+update_caravel: check-caravel
+ifeq ($(SUBMODULE),1)
+	@git submodule update --init --recursive
+	cd $(CARAVEL_ROOT) && \
+	git checkout $(CARAVEL_BRANCH) && \
+	git pull
+else
+	cd $(CARAVEL_ROOT)/ && \
+		git checkout $(CARAVEL_BRANCH) && \
+		git pull
+endif
+
+# Uninstall Caravel
+.PHONY: uninstall
+uninstall: 
+ifeq ($(SUBMODULE),1)
+	git config -f .gitmodules --remove-section "submodule.$(CARAVEL_NAME)"
+	git add .gitmodules
+	git submodule deinit -f $(CARAVEL_ROOT)
+	git rm --cached $(CARAVEL_ROOT)
+	rm -rf .git/modules/$(CARAVEL_NAME)
+	rm -rf $(CARAVEL_ROOT)
+else
+	rm -rf $(CARAVEL_ROOT)
+endif
+
+# Install Openlane
+.PHONY: openlane
+openlane: 
+	cd openlane && $(MAKE) openlane
+
+# Install Pre-check
+# Default installs to the user home directory, override by "export PRECHECK_ROOT=<precheck-installation-path>"
+.PHONY: precheck
+precheck:
+	@git clone https://github.com/efabless/mpw_precheck.git --depth=1 $(PRECHECK_ROOT)
+	@docker pull efabless/mpw_precheck:latest
+
+.PHONY: run-precheck
+run-precheck: check-precheck check-pdk check-caravel
+	$(eval INPUT_DIRECTORY := $(shell pwd))
+	cd $(PRECHECK_ROOT) && \
+	docker run -e INPUT_DIRECTORY=$(INPUT_DIRECTORY) -e PDK_ROOT=$(PDK_ROOT) -e CARAVEL_ROOT=$(CARAVEL_ROOT) -v $(PRECHECK_ROOT):$(PRECHECK_ROOT) -v $(INPUT_DIRECTORY):$(INPUT_DIRECTORY) -v $(PDK_ROOT):$(PDK_ROOT) -v $(CARAVEL_ROOT):$(CARAVEL_ROOT) \
+	-u $(shell id -u $(USER)):$(shell id -g $(USER)) efabless/mpw_precheck:latest bash -c "cd $(PRECHECK_ROOT) ; python3 mpw_precheck.py --pdk_root $(PDK_ROOT) --input_directory $(INPUT_DIRECTORY) --caravel_root $(CARAVEL_ROOT)"
+
+# Install PDK using OL's Docker Image
+.PHONY: pdk-nonnative
+pdk-nonnative: skywater-pdk skywater-library skywater-timing open_pdks
+	docker run --rm -v $(PDK_ROOT):$(PDK_ROOT) -v $(CARAVEL_ROOT):$(CARAVEL_ROOT) -e CARAVEL_ROOT=$(CARAVEL_ROOT) -e PDK_ROOT=$(PDK_ROOT) -u $(shell id -u $(USER)):$(shell id -g $(USER)) efabless/openlane:current sh -c "cd $(CARAVEL_ROOT); make build-pdk; make gen-sources"
+
+# Clean 
+.PHONY: clean
+clean:
+	cd ./verilog/dv/ && \
+		$(MAKE) -j$(THREADS) clean
+
+check-caravel:
+	@if [ ! -d "$(CARAVEL_ROOT)" ]; then \
+		echo "Caravel Root: "$(CARAVEL_ROOT)" doesn't exists, please export the correct path before running make. "; \
+		exit 1; \
+	fi
+
+check-precheck:
+	@if [ ! -d "$(PRECHECK_ROOT)" ]; then \
+		echo "Pre-check Root: "$(PRECHECK_ROOT)" doesn't exists, please export the correct path before running make. "; \
+		exit 1; \
+	fi
+
+check-pdk:
+	@if [ ! -d "$(PDK_ROOT)" ]; then \
+		echo "PDK Root: "$(PDK_ROOT)" doesn't exists, please export the correct path before running make. "; \
+		exit 1; \
+	fi
+
+.PHONY: help
+help:
+	cd $(CARAVEL_ROOT) && $(MAKE) help 
+	@$(MAKE) -pRrq -f $(lastword $(MAKEFILE_LIST)) : 2>/dev/null | awk -v RS= -F: '/^# File/,/^# Finished Make data base/ {if ($$1 !~ "^[#.]") {print $$1}}' | sort | egrep -v -e '^[^[:alnum:]]' -e '^$@$$'
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..8c8c2b8
--- /dev/null
+++ b/README.md
@@ -0,0 +1,18 @@
+# RRAM_4T1R
+
+[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) [![CI](https://github.com/lnis-uofu/testchip_4t1r/actions/workflows/user_project_ci.yml/badge.svg)](https://github.com/lnis-uofu/testchip_4t1r/actions/workflows/user_project_ci.yml) [![Caravan Build](https://github.com/lnis-uofu/testchip_4t1r/actions/workflows/caravan_build.yml/badge.svg)](https://github.com/lnis-uofu/testchip_4t1r/actions/workflows/caravan_build.yml)
+
+---
+
+| :exclamation: Important Note            |
+|-----------------------------------------|
+
+## Please fill in your project documentation in this README.md file 
+
+
+:warning: | Use this sample project for analog user projects. 
+:---: | :---
+
+---
+
+Refer to [README](docs/source/index.rst) for this sample project documentation.