list_repo_files
Browse files- .gitignore +2 -1
- hugging_face.ipynb +21 -15
.gitignore
CHANGED
@@ -1,2 +1,3 @@
|
|
1 |
*.env
|
2 |
-
auth*
|
|
|
|
1 |
*.env
|
2 |
+
auth*
|
3 |
+
*.pyc
|
hugging_face.ipynb
CHANGED
@@ -12,22 +12,22 @@
|
|
12 |
},
|
13 |
{
|
14 |
"cell_type": "code",
|
15 |
-
"execution_count":
|
16 |
"metadata": {},
|
17 |
"outputs": [
|
18 |
{
|
19 |
"name": "stdout",
|
20 |
"output_type": "stream",
|
21 |
"text": [
|
22 |
-
"Token will not been saved to git credential helper. Pass `add_to_git_credential=True` if you want to set the git credential as well.\n",
|
23 |
"Token is valid.\n",
|
|
|
24 |
"Your token has been saved to /home/dulunche/.cache/huggingface/token\n",
|
25 |
"Login successful\n"
|
26 |
]
|
27 |
}
|
28 |
],
|
29 |
"source": [
|
30 |
-
"login(token=HFW_TOKEN)"
|
31 |
]
|
32 |
},
|
33 |
{
|
@@ -114,24 +114,30 @@
|
|
114 |
},
|
115 |
{
|
116 |
"cell_type": "code",
|
117 |
-
"execution_count":
|
118 |
"metadata": {},
|
119 |
"outputs": [
|
120 |
{
|
121 |
-
"
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
|
|
|
|
|
|
131 |
}
|
132 |
],
|
133 |
"source": [
|
134 |
-
"api.
|
|
|
|
|
|
|
135 |
]
|
136 |
}
|
137 |
],
|
|
|
12 |
},
|
13 |
{
|
14 |
"cell_type": "code",
|
15 |
+
"execution_count": 23,
|
16 |
"metadata": {},
|
17 |
"outputs": [
|
18 |
{
|
19 |
"name": "stdout",
|
20 |
"output_type": "stream",
|
21 |
"text": [
|
|
|
22 |
"Token is valid.\n",
|
23 |
+
"Your token has been saved in your configured git credential helpers (cache).\n",
|
24 |
"Your token has been saved to /home/dulunche/.cache/huggingface/token\n",
|
25 |
"Login successful\n"
|
26 |
]
|
27 |
}
|
28 |
],
|
29 |
"source": [
|
30 |
+
"login(token=HFW_TOKEN, add_to_git_credential=True)"
|
31 |
]
|
32 |
},
|
33 |
{
|
|
|
114 |
},
|
115 |
{
|
116 |
"cell_type": "code",
|
117 |
+
"execution_count": 27,
|
118 |
"metadata": {},
|
119 |
"outputs": [
|
120 |
{
|
121 |
+
"data": {
|
122 |
+
"text/plain": [
|
123 |
+
"['.gitattributes',\n",
|
124 |
+
" '.gitignore',\n",
|
125 |
+
" 'README.md',\n",
|
126 |
+
" 'app.py',\n",
|
127 |
+
" 'hugging_face.ipynb',\n",
|
128 |
+
" 'requirements.txt']"
|
129 |
+
]
|
130 |
+
},
|
131 |
+
"execution_count": 27,
|
132 |
+
"metadata": {},
|
133 |
+
"output_type": "execute_result"
|
134 |
}
|
135 |
],
|
136 |
"source": [
|
137 |
+
"api.list_repo_files(\n",
|
138 |
+
" repo_id='drclab/ChatDulun',\n",
|
139 |
+
" repo_type='space'\n",
|
140 |
+
")"
|
141 |
]
|
142 |
}
|
143 |
],
|