Not-Grim-Refer commited on
Commit
e113367
·
1 Parent(s): 14ba0dd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -0
app.py CHANGED
@@ -2,6 +2,7 @@ import os
2
  import streamlit as st
3
  from github import Github
4
  from github import GithubException
 
5
 
6
  # Set up the Streamlit app
7
  st.set_page_config(page_title="GitHub File Search", page_icon=":mag_right:", theme="dark")
@@ -59,6 +60,16 @@ def app():
59
  else:
60
  st.warning(f"No repositories found with the file '{filename}'.")
61
 
 
 
 
 
 
 
 
 
 
 
62
  # Run the Streamlit app
63
  if __name__ == "__main__":
64
  app()
 
2
  import streamlit as st
3
  from github import Github
4
  from github import GithubException
5
+ from altair import Chart
6
 
7
  # Set up the Streamlit app
8
  st.set_page_config(page_title="GitHub File Search", page_icon=":mag_right:", theme="dark")
 
60
  else:
61
  st.warning(f"No repositories found with the file '{filename}'.")
62
 
63
+ # Create a chart to show the number of repositories found for each file name
64
+ chart = Chart(data=repo_info).mark_bar().encode(
65
+ x='name',
66
+ y='count',
67
+ color='name'
68
+ )
69
+
70
+ # Display the chart
71
+ st.plotly_chart(chart)
72
+
73
  # Run the Streamlit app
74
  if __name__ == "__main__":
75
  app()