Merge pull request #3177 from orestisf1993/trailing

Remove trailing whitespace from Perl scripts
This commit is contained in:
Ingo Bürk 2018-03-15 20:41:47 +01:00 committed by GitHub
commit 965ef8d33f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 16 additions and 16 deletions

View File

@ -77,7 +77,7 @@ for my $line (@lines) {
($line =~ / ($line =~ /
^\s* # skip leading whitespace ^\s* # skip leading whitespace
([a-z_]+ \s* = \s*|) # optional identifier ([a-z_]+ \s* = \s*|) # optional identifier
(.*?) -> \s* # token (.*?) -> \s* # token
(.*) # optional action (.*) # optional action
/x); /x);

View File

@ -14,7 +14,7 @@
# #
# • http://onyxneon.com/books/modern_perl/modern_perl_a4.pdf # • http://onyxneon.com/books/modern_perl/modern_perl_a4.pdf
# (unless you are already familiar with Perl) # (unless you are already familiar with Perl)
# #
# #
use i3test; use i3test;

View File

@ -45,7 +45,7 @@ is($x->input_focus, $win3->{id}, 'it should not disturb focus');
############################################################################### ###############################################################################
# test all window types # test all window types
my %window_types = ( my %window_types = (
'normal' => '_NET_WM_WINDOW_TYPE_NORMAL', 'normal' => '_NET_WM_WINDOW_TYPE_NORMAL',
'dialog' => '_NET_WM_WINDOW_TYPE_DIALOG', 'dialog' => '_NET_WM_WINDOW_TYPE_DIALOG',
'utility' => '_NET_WM_WINDOW_TYPE_UTILITY', 'utility' => '_NET_WM_WINDOW_TYPE_UTILITY',

View File

@ -22,7 +22,7 @@ use List::Util qw(first);
my ($config, $pid, $first, $second, $ws1, $ws2); my ($config, $pid, $first, $second, $ws1, $ws2);
sub send_net_active_window { sub send_net_active_window {
my ($id) = @_; my ($id) = @_;
my $msg = pack "CCSLLLLLLL", my $msg = pack "CCSLLLLLLL",
X11::XCB::CLIENT_MESSAGE, # response_type X11::XCB::CLIENT_MESSAGE, # response_type

View File

@ -31,7 +31,7 @@ my $_NET_WM_STATE_ADD = 1;
my $_NET_WM_STATE_TOGGLE = 2; my $_NET_WM_STATE_TOGGLE = 2;
sub set_urgency { sub set_urgency {
my ($win, $urgent_flag) = @_; my ($win, $urgent_flag) = @_;
my $msg = pack "CCSLLLLLL", my $msg = pack "CCSLLLLLL",
X11::XCB::CLIENT_MESSAGE, # response_type X11::XCB::CLIENT_MESSAGE, # response_type
32, # format 32, # format
@ -119,7 +119,7 @@ is($nodes->[0]->{window}, $M->{id}, 'M is left of S');
is($nodes->[1]->{window}, $S->{id}, 'S is right of M'); is($nodes->[1]->{window}, $S->{id}, 'S is right of M');
############################################################################### ###############################################################################
# Given 'S' and 'M' on different workspaces and 'S' is urgent, when 'S' is # Given 'S' and 'M' on different workspaces and 'S' is urgent, when 'S' is
# moved to 'M', then the urgency flag is transferred to the target workspace. # moved to 'M', then the urgency flag is transferred to the target workspace.
############################################################################### ###############################################################################

View File

@ -58,7 +58,7 @@ exit_gracefully($pid);
########################################################################## ##########################################################################
# Given a floating container and the cursor is in the left upper edge # Given a floating container and the cursor is in the left upper edge
# of the output, when moving the container to the mouse, then the # of the output, when moving the container to the mouse, then the
# container is moved but adjusted to stay in-bounds. # container is moved but adjusted to stay in-bounds.
########################################################################## ##########################################################################
@ -84,7 +84,7 @@ exit_gracefully($pid);
########################################################################## ##########################################################################
# Given a floating container and the cursor is in the left right lower # Given a floating container and the cursor is in the left right lower
# edge of the output, when moving the container to the mouse, then the # edge of the output, when moving the container to the mouse, then the
# container is moved but adjusted to stay in-bounds. # container is moved but adjusted to stay in-bounds.
########################################################################## ##########################################################################

View File

@ -21,15 +21,15 @@ use X11::XCB qw(:all);
sub get_wm_state { sub get_wm_state {
sync_with_i3; sync_with_i3;
my ($con) = @_; my ($con) = @_;
my $cookie = $x->get_property( my $cookie = $x->get_property(
0, 0,
$con->{id}, $con->{id},
$x->atom(name => '_NET_WM_STATE')->id, $x->atom(name => '_NET_WM_STATE')->id,
GET_PROPERTY_TYPE_ANY, GET_PROPERTY_TYPE_ANY,
0, 0,
4096 4096
); );
my $reply = $x->get_property_reply($cookie->{sequence}); my $reply = $x->get_property_reply($cookie->{sequence});
my $len = $reply->{length}; my $len = $reply->{length};

View File

@ -31,15 +31,15 @@ use X11::XCB qw(:all);
sub get_net_wm_desktop { sub get_net_wm_desktop {
sync_with_i3; sync_with_i3;
my ($con) = @_; my ($con) = @_;
my $cookie = $x->get_property( my $cookie = $x->get_property(
0, 0,
$con->{id}, $con->{id},
$x->atom(name => '_NET_WM_DESKTOP')->id, $x->atom(name => '_NET_WM_DESKTOP')->id,
$x->atom(name => 'CARDINAL')->id, $x->atom(name => 'CARDINAL')->id,
0, 0,
1 1
); );
my $reply = $x->get_property_reply($cookie->{sequence}); my $reply = $x->get_property_reply($cookie->{sequence});
return undef if $reply->{length} != 1; return undef if $reply->{length} != 1;