{% set version = "2021.5.30" %}

package:
  name: ca-certificates
  version: {{ version }}

source:
  url: https://pypi.io/packages/source/c/certifi/certifi-{{ version }}.tar.gz
  sha256: 2bbf76fd432960138b3ef6dda3dde0544f27cbf8546c458e60baf371917ba9ee

build:
  number: 0

test:
  requires:
    - curl

  commands:
    # Verify the certificates are there.
    - test -f "${PREFIX}/ssl/cacert.pem"                                      # [unix]
    - test -f "${PREFIX}/ssl/cert.pem"                                        # [unix]
    - if not exist %LIBRARY_PREFIX%\\ssl\\cacert.pem exit 1                   # [win]
    - if not exist %LIBRARY_PREFIX%\\ssl\\cert.pem exit 1                     # [win]

    # Use the certificates to download something.
    - curl --cacert "${PREFIX}/ssl/cacert.pem" https://www.google.com         # [unix]
    - curl --cacert %LIBRARY_PREFIX%\\ssl\\cacert.pem https://www.google.com  # [win]

about:
  home: https://github.com/conda-forge/ca-certificates-feedstock
  license: ISC
  license_file: LICENSE
  summary: Certificates for use with other packages.

extra:
  recipe-maintainers:
    - jakirkham
    - msarahan
    - mwcraig
    - ocefpaf
    - patricksnape
    - pelson
    - scopatz
