Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does the "checkout" step in circle ci do?

Circle CI has a "config.yml" file. This file contains the configuration and it contains the steps in a job. There is a "checkout" included in the steps of the config.yml. what does the "checkout" do?

This is a how a basic sample config for circleci look like:

version: 2
jobs:
  build:
    docker:
      - image: alpine:3.7
    steps:
      - checkout
      - run:
          name: The First Step
          command: |
            echo 'Hello World!'
like image 803
Puja Bhattacharya Avatar asked Nov 17 '22 00:11

Puja Bhattacharya


1 Answers

What does the "checkout" do? Special step used to check out source code to the configured path (defaults to the working_directory). The reason this is a special step is because it is more of a helper function designed to make checking out code easy for you.

Additional Info: https://circleci.com/docs/2.0/configuration-reference/#checkout In the case of checkout, the step type is just a string with no additional attributes: - checkout

like image 107
Puja Bhattacharya Avatar answered Apr 28 '23 06:04

Puja Bhattacharya