Skip to content

Default configuration for Firebase repos

Notifications You must be signed in to change notification settings

Dimvy-Clothing-brand/.github

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cache Dependencies and Build Outputs in GitHub Actions

This repository provides a solution for caching dependencies and build outputs in GitHub Actions, which helps improve the speed and efficiency of your CI/CD workflows.

Table of Contents

Overview

Caching dependencies and build outputs can significantly reduce the time it takes to run your CI/CD pipelines by reusing previously built artifacts and dependencies. This repository contains the necessary configurations and scripts to set up caching in your GitHub Actions workflows.

Features

  • TypeScript: 98%
  • Shell: 1.1%
  • JavaScript: 0.9%
  • Efficient caching of dependencies and build outputs
  • Easy integration with existing GitHub Actions workflows
  • Example configurations provided

Installation

To use this caching solution in your GitHub Actions workflows, add the relevant configuration to your workflow YAML files.

Usage

Here's an example of how to use this caching solution in a GitHub Actions workflow:

name: CI

on: [push, pull_request]

jobs:
  build:
    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2

    - name: Set up Node.js
      uses: actions/setup-node@v2
      with:
        node-version: '14'

    - name: Cache dependencies
      uses: actions/cache@v2
      with:
        path: ~/.npm
        key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
        restore-keys: |
          ${{ runner.os }}-node-

    - run: npm install
    - run: npm run build