-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (29 loc) · 1.43 KB
/
slb.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
name: SLB
on:
push:
branches:
- main
workflow_dispatch:
schedule:
- cron: '*/15 3-11 * * 1-5'
jobs:
scheduled:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v2
with:
persist-credentials: false
fetch-depth: 0
- name: Open page and save cookies
run: |
curl 'https://www.nseindia.com/products-services/equity-derivatives-individual-securities' --header 'authority: www.nseindia.com' --header 'accept: */*' --header 'accept-language: en' --header 'dnt: 1' --header 'user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36' --header 'x-requested-with: XMLHttpRequest' --cookie-jar cookies.txt --compressed
- name: read cookies and fetch file
id: cookies
run: |
curl 'https://nsearchives.nseindia.com/content/fo/NSE_FO_SosScheme.csv' --header 'authority: www.nseindia.com' --header 'accept: */*' --header 'accept-language: en' --header 'dnt: 1' --header 'user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36' --header 'x-requested-with: XMLHttpRequest' --compressed -b cookies.txt > fno.csv
- name: Commit & Push changes
uses: actions-js/push@master
with:
github_token: ${{ secrets.PAT }}
branch: master