-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 7cacdf0
Showing
8 changed files
with
309 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
#Mac | ||
.DS_Store | ||
|
||
#PyCharm | ||
.idea | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# C extensions | ||
*.so | ||
|
||
# Distribution / packaging | ||
.Python | ||
env/ | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
wheels/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
|
||
# PyInstaller | ||
# Usually these files are written by a python script from a template | ||
# before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
*.manifest | ||
*.spec | ||
|
||
# Installer logs | ||
pip-log.txt | ||
pip-delete-this-directory.txt | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*,cover | ||
.hypothesis/ | ||
|
||
# Translations | ||
*.mo | ||
*.pot | ||
|
||
# Django stuff: | ||
*.log | ||
local_settings.py | ||
|
||
# Flask stuff: | ||
instance/ | ||
.webassets-cache | ||
|
||
# Scrapy stuff: | ||
.scrapy | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
|
||
# PyBuilder | ||
target/ | ||
|
||
# Jupyter Notebook | ||
.ipynb_checkpoints | ||
|
||
# pyenv | ||
.python-version | ||
|
||
# celery beat schedule file | ||
celerybeat-schedule | ||
|
||
# SageMath parsed files | ||
*.sage.py | ||
|
||
# dotenv | ||
.env | ||
|
||
# virtualenv | ||
.venv | ||
venv/ | ||
ENV/ | ||
|
||
# Spyder project settings | ||
.spyderproject | ||
.spyproject | ||
|
||
# Rope project settings | ||
.ropeproject | ||
|
||
# mkdocs documentation | ||
/site | ||
|
||
# mypy | ||
.mypy_cache/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
web: python hello.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import os | ||
from flask import Flask, render_template,request | ||
import random | ||
|
||
app = Flask(__name__) | ||
|
||
|
||
nucleotide = ["A","G","T","C"] | ||
|
||
@app.route('/') | ||
def hello(): | ||
return render_template("index.html") | ||
|
||
@app.route('/', methods=['POST']) | ||
def hello1(): | ||
len = request.form['len'] | ||
seq = ''.join([random.choice(nucleotide) | ||
for nuc in range(int(len))]) | ||
# processed_text = text.upper() | ||
x = 1 | ||
return render_template("index.html", seq = seq , x=x) | ||
|
||
if __name__ == '__main__': | ||
port = int(os.environ.get("PORT", 5000)) | ||
app.run(debug=True) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
click==7.1.2 | ||
Flask==1.1.2 | ||
itsdangerous==1.1.0 | ||
Jinja2==2.11.2 | ||
MarkupSafe==1.1.1 | ||
Werkzeug==1.0.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
@import "https://fonts.googleapis.com/css?family=Poppins:300,400,500,600,700"; | ||
body { | ||
font-family: 'Poppins', sans-serif; | ||
height: 100%; | ||
background-color: #ffba08; | ||
} | ||
|
||
h1{ | ||
color: #000000; | ||
} | ||
|
||
input[type=number], input[type=] { | ||
width: 40%; | ||
padding: 12px 20px; | ||
margin: 8px 0; | ||
box-sizing: border-box; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
@import "https://fonts.googleapis.com/css?family=Poppins:300,400,500,600,700"; | ||
body { | ||
font-family: 'Poppins', sans-serif; | ||
height: 100%; | ||
background-color: #ffba08; | ||
} | ||
|
||
h1{ | ||
color: #000000; | ||
} | ||
|
||
input{ | ||
width: 40%; | ||
padding: 12px 20px; | ||
margin: 8px 0; | ||
box-sizing: border-box; | ||
} | ||
|
||
div { | ||
border-radius: 5px; | ||
padding: 20px; | ||
} | ||
|
||
input[type=text], select { | ||
width: 100%; | ||
padding: 12px 20px; | ||
margin: 8px 0; | ||
display: inline-block; | ||
border: 1px solid #ccc; | ||
border-radius: 4px; | ||
box-sizing: border-box; | ||
} | ||
|
||
input[type=submit] { | ||
width: 100%; | ||
background-color: #000000; | ||
color: white; | ||
padding: 14px 20px; | ||
margin: 8px 0; | ||
border: none; | ||
border-radius: 4px; | ||
cursor: pointer; | ||
} | ||
|
||
input[type=submit]:hover { | ||
background-color: #343a40; | ||
} | ||
|
||
.btn{ | ||
color : #ffba08; | ||
background-color: #000000; | ||
} | ||
|
||
.btn:hover { | ||
color : #ffba08; | ||
background-color: #343a40 ; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<!DOCTYPE html> | ||
<html lang='en'> | ||
|
||
<head> | ||
<meta class="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> | ||
<title>Page Not Found</title> | ||
<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css"> | ||
<script src="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js"></script> | ||
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> | ||
<link rel="apple-touch-icon" sizes="180x180" href="static/images/apple-touch-icon.png"> | ||
<link rel="icon" type="image/png" sizes="32x32" href="static/images/favicon-32x32.png"> | ||
<link rel="icon" type="image/png" sizes="16x16" href="static/images/favicon-16x16.png"> | ||
<link rel="manifest" href="static/images/site.webmanifest"> | ||
<style> | ||
body { | ||
background-image: linear-gradient(to right, #4facfe 0%, #00f2fe 100%); | ||
} | ||
|
||
.page-wrap { | ||
min-height: 100vh; | ||
} | ||
|
||
.display-4 { | ||
color: white; | ||
} | ||
|
||
.abc { | ||
color: white; | ||
text-decoration: underline; | ||
text-decoration-color: rgb(0, 0, 255); | ||
} | ||
</style> | ||
</head> | ||
|
||
|
||
<body> | ||
<div class="page-wrap d-flex flex-row align-items-center"> | ||
<div class="container"> | ||
<div class="row justify-content-center"> | ||
<div class="col-md-12 text-center"> | ||
<span class="display-4 d-block">Go <a href="/" class="abc">Home</a>, You are drunk.</span> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</body> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
<head> | ||
<!-- Required meta tags --> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> | ||
|
||
<!-- Bootstrap CSS --> | ||
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.0/css/bootstrap.min.css" integrity="sha384-9aIt2nRpC12Uk9gS9baDl411NQApFmC26EwAOH8WgZl5MYYxFfc+NcPb1dKGj7Sk" crossorigin="anonymous"> | ||
<link rel='stylesheet' href="{{ url_for('static', filename='css/style.css') }}" > | ||
<title>Nucleotide Generator</title> | ||
</head> | ||
<body> | ||
<div class="container text-center mt-5"> | ||
<h1>Nucleotide Sequence Generator</h1> | ||
<!-- <input type="number" id="count"> --> | ||
<form method="POST"> | ||
<div class="row"> | ||
<div class="col"> | ||
<label for="fname">Enter length of nucleotides below</label> | ||
<input class="form-control form-control-lg" type="number" name="len" placeholder="Enter length of nucleotides" required> | ||
</div> | ||
|
||
</div> | ||
<button class="btn mb-4" type="submit">Submit</button> | ||
</form> | ||
{% if x == 1 %} | ||
<P>Generated Nucleotide sequence is :</P> | ||
<h3 class="text-break" id="myInput">{{ seq }}</h3> | ||
<button class="btn mt-2" data-clipboard-target="#myInput">Copy Sequence</button> | ||
{% endif %} | ||
|
||
|
||
|
||
</div> | ||
|
||
<!-- Optional JavaScript --> | ||
<!-- jQuery first, then Popper.js, then Bootstrap JS --> | ||
<script src="https://code.jquery.com/jquery-3.5.1.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script> | ||
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/umd/popper.min.js" integrity="sha384-Q6E9RHvbIyZFJoft+2mJbHaEWldlvI9IOYy5n3zV9zzTtmI3UksdQRVvoxMfooAo" crossorigin="anonymous"></script> | ||
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.0/js/bootstrap.min.js" integrity="sha384-OgVRvuATP1z7JjHLkuOU7Xw704+h835Lr+6QL9UvYjZE3Ipu6Tp75j7Bh/kR0JKI" crossorigin="anonymous"></script> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.4/clipboard.min.js"></script> | ||
<script type="text/javascript"> | ||
new ClipboardJS('.btn'); | ||
</script> | ||
</body> | ||
</html> |