Skip to content

Commit ba7235c

Browse files
committed
initial
1 parent 4924c3a commit ba7235c

File tree

272 files changed

+8254
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

272 files changed

+8254
-0
lines changed

Storage.py

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
import sys, os
2+
projectpath = os.path.dirname(os.path.realpath('Storage.py'))
3+
libpath = projectpath + '/lib'
4+
sys.path.append(libpath)
5+
os.chdir(projectpath)
6+
import parsing
7+
import re
8+
import time
9+
10+
# Indexing
11+
startTime = time.time()
12+
index = {}
13+
# What collection to index?
14+
collection = 'New Testament'
15+
# Indicate the path where relative to the collection
16+
os.chdir(projectpath + '/data/' + collection)
17+
# List all files in the collection
18+
files = [file for file in os.listdir('.') if os.path.isfile(file)]
19+
# Iterate through every file
20+
for file in files:
21+
# Split the file in lines
22+
data = open(file).read().splitlines()
23+
# Normalize the content
24+
words = parsing.clean(data)
25+
# Remove the extension from the file for storage
26+
name = re.match('(^[^.]*)', file).group(0)
27+
# Add the words to the index
28+
parsing.index(name, words, index)
29+
print("Indexation took " + str(time.time() - startTime) + " seconds.")
30+
31+
# Storage
32+
startTime = time.time()
33+
parsing.store(index, collection)
34+
print("Storage took " + str(time.time() - startTime) + " seconds.")

browser.ui

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ui version="4.0">
3+
<class>MainWindow</class>
4+
<widget class="QMainWindow" name="MainWindow">
5+
<property name="geometry">
6+
<rect>
7+
<x>0</x>
8+
<y>0</y>
9+
<width>550</width>
10+
<height>574</height>
11+
</rect>
12+
</property>
13+
<property name="windowTitle">
14+
<string>Search Engine</string>
15+
</property>
16+
<widget class="QWidget" name="centralwidget">
17+
<layout class="QGridLayout" name="gridLayout_3">
18+
<item row="0" column="0">
19+
<widget class="QLineEdit" name="lineEdit"/>
20+
</item>
21+
<item row="0" column="1">
22+
<widget class="QPushButton" name="pushButton">
23+
<property name="text">
24+
<string>Search</string>
25+
</property>
26+
</widget>
27+
</item>
28+
<item row="1" column="0" colspan="2">
29+
<widget class="QListWidget" name="listWidget"/>
30+
</item>
31+
</layout>
32+
</widget>
33+
<widget class="QStatusBar" name="statusbar"/>
34+
</widget>
35+
<resources/>
36+
<connections/>
37+
</ui>
+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
1 For I would not, brethren, have you ignorant, that our fathers were all under the cloud, and all passed through the sea;
2+
2 and were all baptized unto Moses in the cloud and in the sea;
3+
3 and did all eat the same spiritual food;
4+
4 and did all drink the same spiritual drink: for they drank of a spiritual rock that followed them: and the rock was Christ.
5+
5 Howbeit with most of them God was not well pleased: for they were overthrown in the wilderness.
6+
6 Now these things were our examples, to the intent we should not lust after evil things, as they also lusted.
7+
7 Neither be ye idolaters, as were some of them; as it is written, The people sat down to eat and drink, and rose up to play.
8+
8 Neither let us commit fornication, as some of them committed, and fell in one day three and twenty thousand.
9+
9 Neither let us make trial of the Lord, as some of them made trial, and perished by the serpents.
10+
10 Neither murmur ye, as some of them murmured, and perished by the destroyer.
11+
11 Now these things happened unto them by way of example; and they were written for our admonition, upon whom the ends of the ages are come.
12+
12 Wherefore let him that thinketh he standeth take heed lest he fall.
13+
13 There hath no temptation taken you but such as man can bear: but God is faithful, who will not suffer you to be tempted above that ye are able; but will with the temptation make also the way of escape, that ye may be able to endure it.
14+
14 Wherefore, my beloved, flee from idolatry.
15+
15 I speak as to wise men; judge ye what I say.
16+
16 The cup of blessing which we bless, is it not a communion of the blood of Christ? The bread which we break, is it not a communion of the body of Christ?
17+
17 seeing that we, who are many, are one bread, one body: for we are all partake of the one bread.
18+
18 Behold Israel after the flesh: have not they that eat the sacrifices communion with the altar?
19+
19 What say I then? that a thing sacrificed to idols is anything, or that an idol is anything?
20+
20 But [I say], that the things which the Gentiles sacrifice, they sacrifice to demons, and not to God: and I would not that ye should have communion with demons.
21+
21 Ye cannot drink the cup of the Lord, and the cup of demons: ye cannot partake of the table of the Lord, and of the table of demons.
22+
22 Or do we provoke the Lord to jealousy? are we stronger than he?
23+
23 All things are lawful; but not all things are expedient. All things are lawful; but not all things edify.
24+
24 Let no man seek his own, but [each] his neighbor's [good].
25+
25 Whatsoever is sold in the shambles, eat, asking no question for conscience' sake,
26+
26 for the earth is the Lord's, and the fulness thereof.
27+
27 If one of them that believe not biddeth you [to a feast], and ye are disposed to go; whatsoever is set before you, eat, asking no question for conscience' sake.
28+
28 But if any man say unto you, This hath been offered in sacrifice, eat not, for his sake that showed it, and for conscience sake:
29+
29 conscience, I say, not thine own, but the other's; for why is my liberty judged by another conscience?
30+
30 If I partake with thankfulness, why am I evil spoken of for that for which I give thanks?
31+
31 Whether therefore ye eat, or drink, or whatsoever ye do, do all to the glory of God.
32+
32 Give no occasions of stumbling, either to Jews, or to Greeks, or to the church of God:
33+
33 even as I also please all men in all things, not seeking mine own profit, but the [profit] of the many, that they may be saved.
+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
1 Be ye imitators of me, even as I also am of Christ.
2+
2 Now I praise you that ye remember me in all things, and hold fast the traditions, even as I delivered them to you.
3+
3 But I would have you know, that the head of every man is Christ; and the head of the woman is the man; and the head of Christ is God.
4+
4 Every man praying or prophesying, having his head covered, dishonoreth his head.
5+
5 But every woman praying or prophesying with her head unveiled dishonoreth her head; for it is one and the same thing as if she were shaven.
6+
6 For if a woman is not veiled, let her also be shorn: but if it is a shame to a woman to be shorn or shaven, let her be veiled.
7+
7 For a man indeed ought not to have his head veiled, forasmuch as he is the image and glory of God: but the woman is the glory of the man.
8+
8 For the man is not of the woman; but the woman of the man:
9+
9 for neither was the man created for the woman; but the woman for the man:
10+
10 for this cause ought the woman to have [a sign of] authority on her head, because of the angels.
11+
11 Nevertheless, neither is the woman without the man, nor the man without the woman, in the Lord.
12+
12 For as the woman is of the man, so is the man also by the woman; but all things are of God.
13+
13 Judge ye in yourselves: is it seemly that a woman pray unto God unveiled?
14+
14 Doth not even nature itself teach you, that, if a man have long hair, it is a dishonor to him?
15+
15 But if a woman have long hair, it is a glory to her: for her hair is given her for a covering.
16+
16 But if any man seemeth to be contentious, we have no such custom, neither the churches of God.
17+
17 But in giving you this charge, I praise you not, that ye come together not for the better but for the worse.
18+
18 For first of all, when ye come together in the church, I hear that divisions exist among you; and I partly believe it.
19+
19 For there must be also factions among you, that they that are approved may be made manifest among you.
20+
20 When therefore ye assemble yourselves together, it is not possible to eat the Lord's supper:
21+
21 for in your eating each one taketh before [other] his own supper; and one is hungry, and another is drunken.
22+
22 What, have ye not houses to eat and to drink in? or despise ye the church of God, and put them to shame that have not? What shall I say to you? shall I praise you? In this I praise you not.
23+
23 For I received of the Lord that which also I delivered unto you, that the Lord Jesus in the night in which he was betrayed took bread;
24+
24 and when he had given thanks, he brake it, and said, This is my body, which is for you: this do in remembrance of me.
25+
25 In like manner also the cup, after supper, saying, This cup is the new covenant in my blood: this do, as often as ye drink [it], in remembrance of me.
26+
26 For as often as ye eat this bread, and drink the cup, ye proclaim the Lord's death till he come.
27+
27 Wherefore whosoever shall eat the bread or drink the cup of the Lord in an unworthy manner, shall be guilty of the body and the blood of the Lord.
28+
28 But let a man prove himself, and so let him eat of the bread, and drink of the cup.
29+
29 For he that eateth and drinketh, eateth and drinketh judgment unto himself, if he discern not the body.
30+
30 For this cause many among you are weak and sickly, and not a few sleep.
31+
31 But if we discerned ourselves, we should not be judged.
32+
32 But when we are judged, we are chastened of the Lord, that we may not be condemned with the world.
33+
33 Wherefore, my brethren, when ye come together to eat, wait one for another.
34+
34 If any man is hungry, let him eat at home; that your coming together be not unto judgment. And the rest will I set in order whensoever I come.
+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
1 Now concerning spiritual [gifts], brethren, I would not have you ignorant.
2+
2 Ye know that when ye were Gentiles [ye were] led away unto those dumb idols, howsoever ye might led.
3+
3 Wherefore I make known unto you, that no man speaking in the Spirit of God saith, Jesus is anathema; and no man can say, Jesus is Lord, but in the Holy Spirit.
4+
4 Now there are diversities of gifts, but the same Spirit.
5+
5 And there are diversities of ministrations, and the same Lord.
6+
6 And there are diversities of workings, but the same God, who worketh all things in all.
7+
7 But to each one is given the manifestation of the Spirit to profit withal.
8+
8 For to one is given through the Spirit the word of wisdom; and to another the word of knowledge, according to the same Spirit:
9+
9 to another faith, in the same Spirit; and to another gifts of healings, in the one Spirit;
10+
10 and to another workings of miracles; and to another prophecy; and to another discernings of spirits; to another [divers] kinds of tongues; and to another the interpretation of tongues:
11+
11 but all these worketh the one and the same Spirit, dividing to each one severally even as he will.
12+
12 For as the body is one, and hath many members, and all the members of the body, being many, are one body; so also is Christ.
13+
13 For in one Spirit were we all baptized into one body, whether Jews or Greeks, whether bond or free; and were all made to drink of one Spirit.
14+
14 For the body is not one member, but many.
15+
15 If the foot shall say, Because I am not the hand, I am not of the body; it is not therefore not of the body.
16+
16 And if the ear shall say, Because I am not the eye, I am not of the body; it is not therefore not of the body.
17+
17 If the whole body were an eye, where were the hearing? If the whole were hearing, where were the smelling?
18+
18 But now hath God set the members each one of them in the body, even as it pleased him.
19+
19 And if they were all one member, where were the body?
20+
20 But now they are many members, but one body.
21+
21 And the eye cannot say to the hand, I have no need of thee: or again the head to the feet, I have no need of you.
22+
22 Nay, much rather, those members of the body which seem to be more feeble are necessary:
23+
23 and those [parts] of the body, which we think to be less honorable, upon these we bestow more abundant honor; and our uncomely [parts] have more abundant comeliness;
24+
24 whereas our comely [parts] have no need: but God tempered the body together, giving more abundant honor to that [part] which lacked;
25+
25 that there should be no schism in the body; but [that] the members should have the same care one for another.
26+
26 And whether one member suffereth, all the members suffer with it; or [one] member is honored, all the members rejoice with it.
27+
27 Now ye are the body of Christ, and severally members thereof.
28+
28 And God hath set some in the church, first apostles, secondly prophets, thirdly teachers, then miracles, then gifts of healings, helps, governments, [divers] kinds of tongues.
29+
29 Are all apostles? are all prophets? are all teachers? are all [workers of] miracles?
30+
30 have all gifts of healings? do all speak with tongues? do all interpret?
31+
31 But desire earnestly the greater gifts. And moreover a most excellent way show I unto you.
+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
1 If I speak with the tongues of men and of angels, but have not love, I am become sounding brass, or a clanging cymbal.
2+
2 And if I have [the gift of] prophecy, and know all mysteries and all knowledge; and if I have all faith, so as to remove mountains, but have not love, I am nothing.
3+
3 And if I bestow all my goods to feed [the poor], and if I give my body to be burned, but have not love, it profiteth me nothing.
4+
4 Love suffereth long, [and] is kind; love envieth not; love vaunteth not itself, is not puffed up,
5+
5 doth not behave itself unseemly, seeketh not its own, is not provoked, taketh not account of evil;
6+
6 rejoiceth not in unrighteousness, but rejoiceth with the truth;
7+
7 beareth all things, believeth all things, hopeth all things, endureth all things.
8+
8 Love never faileth: but whether [there be] prophecies, they shall be done away; whether [there be] tongues, they shall cease; whether [there be] knowledge, it shall be done away.
9+
9 For we know in part, and we prophesy in part;
10+
10 but when that which is perfect is come, that which is in part shall be done away.
11+
11 When I was a child, I spake as a child, I felt as a child, I thought as a child: now that I am become a man, I have put away childish things.
12+
12 For now we see in a mirror, darkly; but then face to face: now I know in part; but then shall I know fully even as also I was fully known.
13+
13 But now abideth faith, hope, love, these three; and the greatest of these is love.
+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
1 Follow after love; yet desire earnestly spiritual [gifts], but rather that ye may prophesy.
2+
2 For he that speaketh in a tongue speaketh not unto men, but unto God; for no man understandeth; but in the spirit he speaketh mysteries.
3+
3 But he that prophesieth speaketh unto men edification, and exhortation, and consolation.
4+
4 He that speaketh in a tongue edifieth himself; but he that prophesieth edifieth the church.
5+
5 Now I would have you all speak with tongues, but rather that ye should prophesy: and greater is he that prophesieth than he that speaketh with tongues, except he interpret, that the church may receive edifying.
6+
6 But now, brethren, if I come unto you speaking with tongues, what shall I profit you, unless I speak to you either by way of revelation, or of knowledge, or of prophesying, or of teaching?
7+
7 Even things without life, giving a voice, whether pipe or harp, if they give not a distinction in the sounds, how shall it be known what is piped or harped?
8+
8 For if the trumpet give an uncertain voice, who shall prepare himself for war?
9+
9 So also ye, unless ye utter by the tongue speech easy to understood, how shall it be known what is spoken? for ye will be speaking into the air.
10+
10 There are, it may be, so many kinds of voices in the world, and no [kind] is without signification.
11+
11 If then I know not the meaning of the voice, I shall be to him that speaketh a barbarian, and he that speaketh will be a barbarian unto me.
12+
12 So also ye, since ye are zealous of spiritual [gifts], seek that ye may abound unto the edifying of the church.
13+
13 Wherefore let him that speaketh in a tongue pray that he may interpret.
14+
14 For if I pray in a tongue, my spirit prayeth, but my understanding is unfruitful.
15+
15 What is it then? I will pray with the spirit, and I will pray with the understanding also: I will sing with the spirit, and I will sing with the understanding also.
16+
16 Else if thou bless with the spirit, how shall he that filleth the place of the unlearned say the Amen at thy giving of thanks, seeing he knoweth not what thou sayest?
17+
17 For thou verily givest thanks well, but the other is not edified.
18+
18 I thank God, I speak with tongues more than you all:
19+
19 howbeit in the church I had rather speak five words with my understanding, that I might instruct others also, than ten thousand words in a tongue.
20+
20 Brethren, be not children in mind: yet in malice be ye babes, but in mind be men.
21+
21 In the law it is written, By men of strange tongues and by the lips of strangers will I speak unto this people; and not even thus will they hear me, saith the Lord.
22+
22 Wherefore tongues are for a sign, not to them that believe, but to the unbelieving: but prophesying [is for a sign], not to the unbelieving, but to them that believe.
23+
23 If therefore the whole church be assembled together and all speak with tongues, and there come in men unlearned or unbelieving, will they not say that ye are mad?
24+
24 But if all prophesy, and there come in one unbelieving or unlearned, he is reproved by all, he is judged by all;
25+
25 the secrets of his heart are made manifest; and so he will fall down on his face and worship God, declaring that God is among you indeed.
26+
26 What is it then, brethren? When ye come together, each one hath a psalm, hath a teaching, hath a revelation, hath a tongue, hath an interpretation. Let all things be done unto edifying.
27+
27 If any man speaketh in a tongue, [let it be] by two, or at the most three, and [that] in turn; and let one interpret:
28+
28 but if there be no interpreter, let him keep silence in the church; and let him speak to himself, and to God.
29+
29 And let the prophets speak [by] two or three, and let the others discern.
30+
30 But if a revelation be made to another sitting by, let the first keep silence.
31+
31 For ye all can prophesy one by one, that all may learn, and all may be exhorted;
32+
32 and the spirits of the prophets are subject to the prophets;
33+
33 for God is not [a God] of confusion, but of peace. As in all the churches of the saints,
34+
34 let the women keep silence in the churches: for it is not permitted unto them to speak; but let them be in subjection, as also saith the law.
35+
35 And if they would learn anything, let them ask their own husbands at home: for it is shameful for a woman to speak in the church.
36+
36 What? was it from you that the word of God went forth? or came it unto you alone?
37+
37 If any man thinketh himself to be a prophet, or spiritual, let him take knowledge of the things which I write unto you, that they are the commandment of the Lord.
38+
38 But if any man is ignorant, let him be ignorant.
39+
39 Wherefore, my brethren, desire earnestly to prophesy, and forbid not to speak with tongues.
40+
40 But let all things be done decently and in order.

0 commit comments

Comments
 (0)