-
Notifications
You must be signed in to change notification settings - Fork 884
56 lines (55 loc) · 2.3 KB
/
create_feedstock_pr.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
on:
workflow_dispatch:
inputs:
version:
description: 'released PyPI version to use (ex - v1.11.1)'
required: true
name: Create Feedstock PR
jobs:
create_feedstock_pr:
name: Create Feedstock PR
runs-on: ubuntu-latest
steps:
- name: Checkout inputted version
uses: actions/checkout@v3
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.inputs.version }}
path: "./featuretools"
- name: Pull latest from upstream for user forked feedstock
run: |
gh auth status
gh repo sync alteryx/featuretools-feedstock --branch main --source conda-forge/featuretools-feedstock --force
env:
GITHUB_TOKEN: ${{ secrets.AUTO_APPROVE_TOKEN }}
- uses: actions/checkout@v3
with:
repository: alteryx/featuretools-feedstock
ref: main
path: "./featuretools-feedstock"
fetch-depth: '0'
- name: Run Create Feedstock meta YAML
id: create-feedstock-meta
uses: alteryx/create-feedstock-meta-yaml@v4
with:
project: "featuretools"
pypi_version: ${{ github.event.inputs.version }}
project_metadata_filepath: "featuretools/pyproject.toml"
meta_yaml_filepath: "featuretools-feedstock/recipe/meta.yaml"
add_to_test_requirements: "graphviz !=2.47.2"
- name: View updated meta yaml
run: cat featuretools-feedstock/recipe/meta.yaml
- name: Push updated yaml
run: |
cd featuretools-feedstock
git config --unset-all http.https://github.com/.extraheader
git config --global user.email "[email protected]"
git config --global user.name "machineAYX Bot"
git remote set-url origin https://${{ secrets.AUTO_APPROVE_TOKEN }}@github.com/alteryx/featuretools-feedstock
git checkout -b ${{ github.event.inputs.version }}
git add recipe/meta.yaml
git commit -m "${{ github.event.inputs.version }}"
git push origin ${{ github.event.inputs.version }}
- name: Adding URL to job output
run: |
echo "Conda Feedstock Pull Request: https://github.com/alteryx/featuretools-feedstock/pull/new/${{ github.event.inputs.version }}" >> $GITHUB_STEP_SUMMARY