def prepare(self): if self.section: self.text = self.term + '#' + self.section url_text = wiki.format_term(self.term) +\ '#' + wiki.format_section(self.section) else: self.text = self.term url_text = wiki.format_term(self.term) self.input.group = lambda x: [None, None, self.text, None][x] self.url = 'http://wiki.apertium.org/wiki/%s' % url_text
def prepare(self): if self.section: self.text = self.term + '#' + self.section url_text = wiki.format_term(self.term) +\ '#' + wiki.format_section(self.section) else: self.text = self.term url_text = wiki.format_term(self.term) self.input.group = lambda x: [None, self.text][x] self.url = 'https://wiki.archlinux.org/index.php/{0}'.format(url_text)
def prepare(self): if self.section: self.text = self.term + '#' + self.section url_text = wiki.format_term(self.term) +\ '#' + wiki.format_section(self.section) else: self.text = self.term url_text = wiki.format_term(self.term) self.input.groups.return_value = [None, self.text] self.url = 'https://vtluug.org/wiki/{0}'.format(url_text)