anchor.diff:  
       services.xserver.displayManager.gdm = {
   
  -      enable = mkOption {
  -        type = types.bool;
  -        default = false;
  -        example = true;
  -        description = ''
  -          Whether to enable GDM as the display manager.
  -          <emphasis>GDM is very experimental and may render system unusable.</emphasis>
  -        '';
  +      enable = mkEnableOption ''
  +        Whether to enable GDM as the display manager.
  +        <emphasis>GDM is very experimental and may render system unusable.</emphasis>
  +      '';
  +
  +      autoLogin = mkOption {
  +        default = {};
  +
  +        type = types.submodule {
  +          options = {
  +            enable = mkOption {
  +              type = types.bool;
  +              default = false;
  +              description = ''
  +                Automatically log in as the sepecified <option>auto.user</option>.
  +              '';
  +            };
  +
  +            user = mkOption {
  +              type = types.nullOr types.str;
  +              default = null;
  +              description = ''
  +                User to be used for the autologin.
  +              '';
  +            };
  +
  +            delay = mkOption {
  +              type = types.int;
  +              default = 0;
  +              description = ''
  +                Seconds of inactivity after which the autologin will be performed.
  +              '';
  +            };
  +
  +          };
  +        };
         };
   
       };
  
positive.code: 
      programs.dconf.profiles.gdm = "${gdm}/share/dconf/profile/gdm";
  
      # GDM LFS PAM modules, adapted somehow to NixOS
      security.pam.services = {
        gdm-launch-environment.text = ''
  
negative.code:         session  optional       pam_permit.so
        '';
  
        gdm.text = ''
          auth     requisite      pam_nologin.so
          auth     required       pam_env.so
  
  