Skip to content

Commit

Permalink
style: Fix typos in multiple files
Browse files Browse the repository at this point in the history
Found via `codespell -S *.po,CHANGES -L dum,clude,nin,sistem`
  • Loading branch information
kianmeng committed Mar 6, 2023
1 parent 40ef31c commit b27bac0
Show file tree
Hide file tree
Showing 30 changed files with 82 additions and 82 deletions.
6 changes: 3 additions & 3 deletions FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ Back In Time now try to find your Snapshots under the new host- and username
underneath the ``/path/to/backintime/`` path.

The *Auto Host/User/Profile ID* option is gone in version 1.1.0 and above.
It was totaly confusing and didn't add any good.
It was totally confusing and didn't add any good.

You have three options to fix this:

Expand Down Expand Up @@ -231,7 +231,7 @@ your system after a disaster/on a new machine.
```

1. Make some *housecleaning* in ``~/.apt-backup/package.list``.
For example you don't want to install the old kernal again.
For example you don't want to install the old kernel again.
So run
```bash
Expand Down Expand Up @@ -750,7 +750,7 @@ of **snapshot0**.

``fileA`` is still untouched, ``fileB`` is still available in two different
versions and ``fileC`` is gone for good. The blocks on your hdd that stored the
data for inode 2 and 3 can now get overriden.
data for inode 2 and 3 can now get overridden.

I hope this will shed a light on the "magic" behind BIT. If it's even more
confusing don't hesitate to ask ;)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ See `common/configure --help` and `qt/configure --help` for details.
### Resources
- [Mailing list _bit-dev_](https://mail.python.org/mailman3/lists/bit-dev.python.org/) for development related topics
- [Source code documentation for developers](https://backintime-dev.readthedocs.org)
- [Translations](https://translations.launchpad.net/backintime) are done on a separate plattform
- [Translations](https://translations.launchpad.net/backintime) are done on a separate platform
### Guidelines & Rules
The maintenance team will welcome all types of contributions. No contribution will be rejected
just because it doesn't fit to our quality standards, guidelines or rules. Every contribution
Expand Down
2 changes: 1 addition & 1 deletion common/backintime.py
Original file line number Diff line number Diff line change
Expand Up @@ -877,7 +877,7 @@ def snapshotsList(args):

def snapshotsListPath(args):
"""
Command for printing a list of all snapshots pathes in current profile.
Command for printing a list of all snapshots paths in current profile.
Args:
args (argparse.Namespace):
Expand Down
2 changes: 1 addition & 1 deletion common/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def errorHandler(msg):
return False
okay()

test = 'Check/prepair snapshot path'
test = 'Check/prepare snapshot path'
announceTest()
snapshots_path = cfg.snapshotsPath(mode = mode, tmp_mount = True)

Expand Down
4 changes: 2 additions & 2 deletions common/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

"""Configuration logic.
This module and its `Config` class contain the appliation logic handling the
This module and its `Config` class contain the application logic handling the
configuration of Back In Time. The handling of the configuration file itself
is separated in the module :py:module:`configfile`.
Expand Down Expand Up @@ -434,7 +434,7 @@ def setSnapshotsPath(self, value, profile_id = None, mode = None):
{'path': value})
return False
elif fs == 'cifs' and not self.copyLinks():
self.notifyError(_("Destination filsystem for '%(path)s' is a SMB mounted share. Please make sure "
self.notifyError(_("Destination filesystem for '%(path)s' is a SMB mounted share. Please make sure "
"the remote SMB server supports symlinks or activate '%(copyLinks)s' in '%(expertOptions)s'.") %
{'path': value,
'copyLinks': _('Copy links (dereference symbolic links)'),
Expand Down
4 changes: 2 additions & 2 deletions common/configfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def save(self, filename):
"""
def numsort(key):
"""
Sort int in keys in nummeric order instead of alphabetical by adding
Sort int in keys in numeric order instead of alphabetical by adding
leading zeros to int's
"""
return re.sub(r'\d+', lambda m: m.group(0).zfill(6), key)
Expand Down Expand Up @@ -187,7 +187,7 @@ def strValue(self, key, default=''):
Return a 'str' instance of key's value.
Args:
key (str): Key identifing the value in the config file.
key (str): Key identifying the value in the config file.
default (str): Default value if ``key`` is not present.
Returns:
Expand Down
4 changes: 2 additions & 2 deletions common/configure
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ for i in "py.test-3" "py.test-3.6" "py.test-3.5" "py.test-3.4"; do
done
COVERAGE=$(which coverage 2>/dev/null)
#use "coverage run" only on travis-ci.org and if it is available
#this will pass informations to coveralls.io.
#this will pass information to coveralls.io.
#otherwise use "python", "python3" or if available "py.test-3"
if onTravis && [ -n "${COVERAGE}" ]; then
CMD="coverage run -p"
Expand All @@ -308,7 +308,7 @@ for v in "" "-v"; do
done
else
#else just call py.test-3 which will find test/test_*.py by itself
#py.test-3 has a nicer output so this is prefered over simple python3
#py.test-3 has a nicer output so this is preferred over simple python3
printf "\t${PYTEST} ${v}\n" >> ${MAKEFILE}
fi
printf "\n" >> ${MAKEFILE}
Expand Down
6 changes: 3 additions & 3 deletions common/create-manpage-backintime-config.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
file.
The file `common/config.py` is parsed for variable names, default values and
other informations. The founder of that script @Germar gave a detailed
other information. The founder of that script @Germar gave a detailed
description about that script in #1354.
The script reads every line and tries to analyse it:
Expand All @@ -42,7 +42,7 @@
`snapshots.include.size`.
In `process_line` it will replace some information with those I wrote manually
in the `#?` description, seperated by `;` there is the comment, value,
in the `#?` description, separated by `;` there is the comment, value,
force_default and force_var. If there is no forced value it will chose the
value based on the instance with `select_values`
"""
Expand Down Expand Up @@ -74,7 +74,7 @@
/etc/backintime/config
.SH DESCRIPTION
Back In Time was developed as pure GUI program and so most functions are only
useable with backintime-qt. But it is possible to use
usable with backintime-qt. But it is possible to use
Back In Time e.g. on a headless server. You have to create the configuration file
(~/.config/backintime/config) manually. Look inside /usr/share/doc/backintime\-common/examples/ for examples.
.PP
Expand Down
4 changes: 2 additions & 2 deletions common/diagnostics.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def collect_diagnostics():

# Display system (X11 or Wayland)
# This doesn't catch all edge cases.
# For more detials see: https://unix.stackexchange.com/q/202891/136851
# For more details see: https://unix.stackexchange.com/q/202891/136851
result['host-setup']['display-system'] = os.environ.get(
'XDG_SESSION_TYPE', '($XDG_SESSION_TYPE not set)')

Expand Down Expand Up @@ -334,7 +334,7 @@ def _replace_username_paths(result, username):
reasons.
Args:
result (dict): Dict possibily containing the username and its home
result (dict): Dict possibly containing the username and its home
path.
username (str). The user login name to look for.
Expand Down
2 changes: 1 addition & 1 deletion common/dummytools.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class Dummy(mount.MountControl):
Please use self.currentMountpoint as your local mountpoint.
This class inherit from mount.MountControl. All methodes from MountControl can
be used exactly like they were in this class.
Methodes from MountControl also can be overriden in here if you need
Methodes from MountControl also can be overridden in here if you need
something different.
"""
def __init__(self, *args, **kwargs):
Expand Down
6 changes: 3 additions & 3 deletions common/encfstools.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ def mount(self, *args, **kwargs):
if not os.path.isfile(self.configFile()):
#encfs >= 1.8.0 changed behavior when ENCFS6_CONFIG environ variable
#file does not exist. It will not create a new one anymore but just fail.
#As encfs would create the config in /.encfs6.xml (which will most likly fail)
#As encfs would create the config in /.encfs6.xml (which will most likely fail)
#we need to mount a temp folder with reverse first and copy the config when done.
logger.debug('Mount temp folder with encfs --reverse to create a new encfs config', self)
with tempfile.TemporaryDirectory() as src:
Expand Down Expand Up @@ -590,8 +590,8 @@ def startProcess(self):

def path(self, path):
"""
write crypted path to encfsctl stdin and read plain path from stdout
if stdout is empty (most likly because there was an error) return crypt path
write encrypted path to encfsctl stdin and read plain path from stdout
if stdout is empty (most likely because there was an error) return crypt path
"""
if self.string:
assert isinstance(path, str), 'path is not str type: %s' % path
Expand Down
2 changes: 1 addition & 1 deletion common/man/C/backintime-config.1
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ config \- BackInTime configuration files.
/etc/backintime/config
.SH DESCRIPTION
Back In Time was developed as pure GUI program and so most functions are only
useable with backintime-qt. But it is possible to use
usable with backintime-qt. But it is possible to use
Back In Time e.g. on a headless server. You have to create the configuration file
(~/.config/backintime/config) manually. Look inside /usr/share/doc/backintime\-common/examples/ for examples.
.PP
Expand Down
4 changes: 2 additions & 2 deletions common/man/C/backintime.1
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ will start in foreground.
remove[\-and\-do\-not\-ask\-again] | \-\-remove[\-and\-do\-not\-ask\-again] [SNAPSHOT_ID]
Remove the snapshot. If SNAPSHOT_ID is missing it will be prompted. SNAPSHOT_ID
can be an index (starting with 0 for the last snapshot) or the exact SnapshotID
(19 caracters like '20130606-230501-984').
(19 characters like '20130606-230501-984').
\fIremove\-and\-do\-not\-ask\-again\fR will remove the snapshot immediately.
Be careful with this!
.TP
Expand All @@ -343,7 +343,7 @@ Restore file WHAT to path WHERE from snapshot SNAPSHOT_ID. If arguments are
missing they will be prompted. To restore to the original path WHERE can be an
empty string '' or just press Enter at the prompt. SNAPSHOT_ID can be an index
(starting with 0 for the last snapshot) or the exact SnapshotID
(19 caracters like '20130606-230501-984')
(19 characters like '20130606-230501-984')
.TP
shutdown
Shutdown the computer after the snapshot is done.
Expand Down
6 changes: 3 additions & 3 deletions common/mount.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ def setDefaultArgs(self):
``self.all_kwargs`` need to be filled through :py:func:`setattrKwargs`
before calling this.
"""
#self.destination should contain all arguments that are nessesary for
#self.destination should contain all arguments that are necessary for
#mount.
args = list(self.all_kwargs.keys())
self.destination = '%s:' % self.all_kwargs['mode']
Expand All @@ -395,7 +395,7 @@ def setDefaultArgs(self):

def mount(self, check = True):
"""
Low-level `mount`. Set mountprocess lock and prepair mount, run checks
Low-level `mount`. Set mountprocess lock and prepare mount, run checks
and than call :py:func:`_mount` for the subclassed backend. Finally set
mount lock and symlink and release mountprocess lock.
Expand Down Expand Up @@ -641,7 +641,7 @@ def createMountStructure(self):
│ │ mountpoint
│ │
│ ├── umount <= ``self.umount_info`` json file with
│ │ all nessesary args for unmount
│ │ all necessary args for unmount
│ │
│ └── locks/ <= ``self.lock_path`` for each process
│ you have a ``<pid>.lock`` file
Expand Down
4 changes: 2 additions & 2 deletions common/password_ipc.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def create(self):

def read(self, timeout = 0):
"""
read from fifo untill timeout. If timeout is 0 it will wait forever
read from fifo until timeout. If timeout is 0 it will wait forever
for input.
"""
#sys.stdout.write('read fifo\n')
Expand All @@ -69,7 +69,7 @@ def read(self, timeout = 0):

def write(self, string, timeout = 0):
"""
write to fifo untill timeout. If timeout is 0 it will wait forever
write to fifo until timeout. If timeout is 0 it will wait forever
for an other process that will read this.
"""
#sys.stdout.write('write fifo\n')
Expand Down
4 changes: 2 additions & 2 deletions common/po/messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ msgstr ""
#: ../../common/config.py:409
#, python-format
msgid ""
"Destination filsystem for '%(path)s' is a SMB mounted share. Please make "
"Destination filesystem for '%(path)s' is a SMB mounted share. Please make "
"sure the remote SMB server supports symlinks or activate '%(copyLinks)s' in "
"'%(expertOptions)s'."
msgstr ""
Expand Down Expand Up @@ -950,7 +950,7 @@ msgid "Changes"
msgstr ""

#: ../../qt/logviewdialog.py:100
msgid "Informations"
msgid "Information"
msgstr ""

#: ../../qt/logviewdialog.py:110
Expand Down
4 changes: 2 additions & 2 deletions common/snapshotlog.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ class SnapshotLog(object):
Args:
cfg (config.Config): current config
profile (int): profile that should be used to indentify the log
profile (int): profile that should be used to identify the log
"""

NONE = 0
Expand Down Expand Up @@ -183,7 +183,7 @@ def append(self, msg, level):
level (int): verbosity level of current line. msg will only be
added to log if level is lower than configured
log level :py:func:`config.Config.logLevel`.
Posible Values:
Possible Values:
:py:data:`SnapshotLog.ERRORS`,
:py:data:`SnapshotLog.CHANGES_AND_ERRORS` or
:py:data:`SnapshotLog.ALL`
Expand Down
24 changes: 12 additions & 12 deletions common/snapshots.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def uid(self, name, callback = None, backup = None):
name (:py:class:`str`, :py:class:`bytes`):
username to search for
callback (method): callable which will handle a given message
backup (int): UID wich will be used if the username is unknown
backup (int): UID which will be used if the username is unknown
on this machine
Returns:
Expand Down Expand Up @@ -227,7 +227,7 @@ def gid(self, name, callback = None, backup = None):
name (:py:class:`str`, :py:class:`bytes`):
groupname to search for
callback (method): callable which will handle a given message
backup (int): GID wich will be used if the groupname is unknown
backup (int): GID which will be used if the groupname is unknown
on this machine
Returns:
Expand Down Expand Up @@ -420,7 +420,7 @@ def restore(self,
callback (method): callable instance which will handle
messages
restore_to (str): full path to restore to. If empty
restore to original destiantion
restore to original destination
delete (bool): delete newer files which are not in the
snapshot
backup (bool): create backup files (*.backup.YYYYMMDD)
Expand Down Expand Up @@ -654,7 +654,7 @@ def remove(self, sid):

def backup(self, force = False):
"""
Wrapper for :py:func:`takeSnapshot` which will prepair and clean up
Wrapper for :py:func:`takeSnapshot` which will prepare and clean up
things for the main :py:func:`takeSnapshot` method. This will check
that no other snapshots are running at the same time, there is nothing
prohibing a new snapshot (e.g. on battery) and the profile is configured
Expand Down Expand Up @@ -824,7 +824,7 @@ def backup(self, force = False):

def filterRsyncProgress(self, line):
"""
Filter rsync's stdout for progress informations and store them in
Filter rsync's stdout for progress information and store them in
'~/.local/share/backintime/worker<N>.progress' file.
Args:
Expand Down Expand Up @@ -1234,7 +1234,7 @@ def smartRemoveKeepAll(self,
max_date (datetime.date): maximum date for snapshots to keep
Returns:
set: set of snapshots that should be keept
set: set of snapshots that should be kept
"""
min_id = SID(min_date, self.config)
max_id = SID(max_date, self.config)
Expand Down Expand Up @@ -1262,7 +1262,7 @@ def smartRemoveKeepFirst(self,
snapshot
Returns:
set: set of snapshots that should be keept
set: set of snapshots that should be kept
"""
min_id = SID(min_date, self.config)
max_id = SID(max_date, self.config)
Expand Down Expand Up @@ -1649,7 +1649,7 @@ def freeSpace(self, now):

def statFreeSpaceLocal(self, path):
"""
Get free space on filsystem containing ``path`` in MiB using
Get free space on filesystem containing ``path`` in MiB using
:py:func:`os.statvfs()`. Depending on remote SFTP server this might fail
on sshfs mounted shares.
Expand All @@ -1671,7 +1671,7 @@ def statFreeSpaceLocal(self, path):

def statFreeSpaceSsh(self):
"""
Get free space on remote filsystem in MiB. This will call ``df`` on
Get free space on remote filesystem in MiB. This will call ``df`` on
remote host and parse its output.
Returns:
Expand Down Expand Up @@ -1729,7 +1729,7 @@ def filter(self,
different snapshots only the first snapshot
will be listed
flag_deep_check (bool): use md5sum to check uniqueness of files.
More acurate but slow
More accurate but slow
list_equal_to (str): full path to file. If not empty only return
snapshots which have exactly the same file
as this file
Expand Down Expand Up @@ -1942,7 +1942,7 @@ def rsyncSuffix(self, includeFolders = None, excludeFolders = None):
encode.exclude(self.config._MOUNT_ROOT)
)])
# TODO: fix bug #561:
# after rsync_exclude we need to explicite include files inside excluded
# after rsync_exclude we need to explicitly include files inside excluded
# folders, recursive exclude folder-content again and finally add the
# rest from rsync_include2
ret.extend(rsync_include)
Expand Down Expand Up @@ -2197,7 +2197,7 @@ def displayID(self):
YYYY-MM-DD HH:MM:SS
Returns:
str: formated sID
str: formatted sID
"""
return "{:04}-{:02}-{:02} {:02}:{:02}:{:02}".format(*self.split())

Expand Down
Loading

0 comments on commit b27bac0

Please sign in to comment.